iterator as a unique name and the enumerate trap

David Bruant bruant.d at gmail.com
Mon Oct 1 06:56:01 PDT 2012


2012/10/1 Tom Van Cutsem <tomvc.be at gmail.com>

> 2012/10/1 Tom Van Cutsem <tomvc.be at gmail.com>
>
>> If yes, then we should ask ourselves the question: is this a useful hook
>> for regular objects to customize? I think it's not, really (bear in mind
>> that enumeration can only generate strings (property names), it's a good
>> deal less generic than iteration)
>>
>
> Put another way: customizing enumeration is meta-programming, customizing
> iteration is not.
>
I had not seen things from that angle, but it seems like a valid reason for
the apparent inconsistent of the proxy handler API.

David
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.mozilla.org/pipermail/es-discuss/attachments/20121001/9684ffcf/attachment.html>


More information about the es-discuss mailing list