Brandon Benvie wrote:
On 7/29/2013 11:33 AM, Kevin Smith wrote:
The value of uniqueness lies in the fact that you can design
protocols without having to globally coordinate on property or method
names. (E.g. iterator)
I think {keys, maps, values} (and the pivot to using Symbols and
functions for them)
BTW that was just one thought (from me), and TC39 went another way to
avoid the 'values'/with incompatibility found via Ext.js. (See the
meeting notes for the first day, about the @unscopeable list.)
demonstrates that a protocol is simply an agreed upon way of
communicating; there's no requirement for uniqueness. Uniqueness has
value in that it prevents accidental collisions. Symbols provide
uniqueness because they are compared by identity, GUIDs provide
uniqueness by having a value that is unlikely to be collided with.
Agreed. There have been GUID collisions in the field with things like
COM IIDs. Rare but possible (spoofed MAC address?). This is not a fatal
flaw, especially if TC39 itself specifies well-known GUIDs, e.g., for
'iterator'. But the lack of a human-readable name is a real drawback IMHO.
/be
_______________________________________________
es-discuss mailing list
[email protected]
https://mail.mozilla.org/listinfo/es-discuss