On 9/10/07, Brendan Eich <[EMAIL PROTECTED]> wrote:
> On Sep 10, 2007, at 2:21 PM, Garrett Smith wrote:

> > The fact that the method
> > was called propertyIsEnumerable instead of isPropertyEnumerable is not
> > great, but the way propertyIsEnumerable is designed is confusing to
> > developers.
>
> I've never heard that complaint directly, or in a
> bugzilla.mozilla.org report. Can you cite complaints anywhere on the
> web? I believe you, but it would be good to have evidence.
>
Web search:
http://livedocs.adobe.com/flashlite/2/main/wwhelp/wwhimpl/common/html/wwhelp.htm?context=LiveDocs_Parts&file=00000728.html
http://www.adobe.com/livedocs/flash/8/main/wwhelp/wwhimpl/common/html/wwhelp.htm?context=LiveDocs_Parts&file=00002578.html

Apparently flash actually has a custom "isPropertyEnumerable" method.
It's on Adobe's website. I don't do Flash, so I can't say much about
it. It looks like a straight rename method, though.

This guy wants a rename, too:
http://lists.macosforge.org/pipermail/webkit-reviews/2005-December/002269.html

isPropertyEnumerable and/or propertyIsEnumerable could return true if
an object can be enumerated in a for-in loop, and  check the prototype
chain.

Given the above change, the old (current) behavior could be achieved with:
r.propertyIsEnumerable( p ) && r.hasOwnProperty( p );

The change would allow for 4 different possibilities of r[ p ]


Garrett

>
> /be
>


-- 
Programming is a collaborative art.
_______________________________________________
Es4-discuss mailing list
Es4-discuss@mozilla.org
https://mail.mozilla.org/listinfo/es4-discuss

Reply via email to