Hi Hans,

'super' refers to the instance, but your static _test isn't part of
the instance, it is part of the class (technically, of the constructor
function). Imagine it as this.prototype.prototype, although it
technically isn't the same (well, maybe it is, I haven't tested it).
It behaves like super would, with the exception of the super() call of
the constructor.
To do what you want, super.constructor._test would probably work (but
again, I haven't tested it).

HTH,
Mark


On 8/20/07, Hans Wichman <[EMAIL PROTECTED]> wrote:
> Hi,
>
> lets say i have a superclass:
>
> class SuperClass {
>  private var _test:String = null;
> }
>
> and a subclass:
>
> class SubClass {
>     private function _testFunction () {
>       super._test = "foo";
> trace (super._test);
> }
> }
>
>
> this traces undefined.
>
> If I remove the super. it works, but I like to know when I'm referencing
> super class fields.
>
> It is fixed as well, when I nicely wrap the setting of _test in a function,
> as I should, but I'm still wondering why it fails.
>
> Any ideas?
>
> greetz
> JC
> _______________________________________________
> Flashcoders@chattyfig.figleaf.com
> To change your subscription options or search the archive:
> http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
>
> Brought to you by Fig Leaf Software
> Premier Authorized Adobe Consulting and Training
> http://www.figleaf.com
> http://training.figleaf.com
>
_______________________________________________
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com

Reply via email to