Deleting Getters and Setters (was Re: Controlling DontEnum...)

Kris Zyp kris at sitepen.com
Mon Mar 17 15:26:03 PDT 2008


> syntax. So only
>
> function get x() ++i;
>
> or similar in a class (static or instance) would make a DontDelete 
> binding, if not a fixture. My two cents,

That an object literal can make a getter that can be deleted, but never 
restored, makes for an odd bit of assymetry doesn't it? A getter can be 
deleted, but not added. But, I agree that a getter generated from an object 
literal should probably still be deletable for compatibility. Too bad there 
isn't a way to add getters to an existing object to restore the symmetry.
Kris 




More information about the Es4-discuss mailing list