getter / setters
rfobic at gmail.com
Thu May 20 13:36:37 PDT 2010
Thanks to everyone for a good explanation, as I was assuming my expectations
were wrong, guess partially, because of the SpiderMonkey's behavior in past
(Thanks Brendan for clearing this up, I was pretty sure that was the
behavior in xulrunner, apparently it's in past now :).
Phone: +31 614 205275
Address: Taksteeg 3 - 4, 1012PB Amsterdam, Netherlands
On Thu, May 20, 2010 at 20:54, Mike Samuel <mikesamuel at gmail.com> wrote:
> 2010/5/20 Oliver Hunt <oliver at apple.com>:
> >> So for a non host object o,
> >> o.x = o.x - 1
> >> should yield a number regardless of the details of any setter for x on
> >> o, assuming o is not frozen and said setter returns normally.
> > The assignment operator is defined in the language fairly clearly in a
> way that means that the behaviour is unaffected by the type of object being
> assigned to -- eg. being a host object or not is (mercifully) not relevant
> Quite right. Sorry for being confusing.
> I ran into a corner case for IE6 and IE7 where postfix ++ does not
> always yield a number, e.g. when applied to some host objects. The
> comment at line 80 of
> is my best recollection.
> > --Oliver
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the es-discuss