1
0
Fork 0

Only adding __self() for instance, not supertype init

closure/master
Mike Gerwitz 2011-03-30 23:31:46 -04:00
parent 6ade1c021f
commit 170eb06af6
1 changed files with 6 additions and 2 deletions

View File

@ -522,8 +522,12 @@ function attachPropInit( prototype, properties, members, cid )
// provide a means to access the actual instance (rather than the // provide a means to access the actual instance (rather than the
// property/visibility object) internally (this will translate to // property/visibility object) internally (this will translate to
// this.__self from within a method) // this.__self from within a method), but only if we're on our final
util.defineSecureProp( vis, '__self', this ); // object (not a parent)
if ( typeof parent_init !== 'function' )
{
util.defineSecureProp( vis, '__self', this );
}
}); });
} }