On Apr 2, 2011, at 1:58 PM, David Bruant wrote:
> I'm surprised by the idea that == could be defined on a per-value
> comparison basis on objects (Array as you give it as an example). It
> doesn't make the relation last throughout the program lifetime (which is
> what I was trying to do and requires a priori arrangements). I would
> expect an equivalence relation to last throughout the program. Like ===
> does.
The use-cases are "operators", generally. Python supports unstratified operator
meta-programming, so you can write __-delimited methods to change the meaning
of programs. This is in the Harmony agenda but not for ES.next:
http://wiki.ecmascript.org/doku.php?id=strawman:value_types
http://wiki.ecmascript.org/doku.php?id=strawman:value_proxies
Pythons API
Virtual Values for Language Extension
It needs more baking. The value proxies idea is nearest but stratifed and
constrained, aimed at efficient implementation of new numeric types. The
ability to add operators to existing objects is not well-explored yet.
/be
_______________________________________________
es-discuss mailing list
[email protected]
https://mail.mozilla.org/listinfo/es-discuss