Re: [Vala] inherited method attributes: instancepos inconsistencies
- From: Jürg Billeter <j bitron ch>
- To: Sam Liddicott <sam liddicott com>
- Cc: gege2061 gmail com, vala-list gnome org
- Subject: Re: [Vala] inherited method attributes: instancepos inconsistencies
- Date: Wed, 23 Jul 2008 11:40:39 +0200
On Thu, 2008-06-26 at 15:09 +0100, Sam Liddicott wrote:
We see that the last function (above) has the arguments the wrong way
around because I had removed the instance_pos.
But in fact it is only the entry method that needs to take into account
instance_pos when ordering it's declared arguments.
The inner "real" methods can be "normal" without any strange calling
conventions, and the entry dispatching method could "know" this.
And so I'm really suggesting that for virtual methods, instance_pos only
apply to the wrapper and not to the real functions at all.
It would then be illegal to specify instance_pos on override methods,
only on virtual methods.
It depends on the use case. For your example, it would certainly make
sense to only change the wrapper, however, in other cases, it might be
necessary to apply the attribute to both, the wrapper and the real
function, to be compatible with existing libraries.
If this idea isn't taken up, then consistency should at least be
enforced across all overriddings of the method.
Yes, it's clearly a bug as it is now.
Juerg
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]