Re: [Harmony proxies] add receiver as a first argument to all prototype-climbing traps

2011-04-08 Thread David Bruant
Le 07/04/2011 20:39, Brendan Eich a écrit : On Apr 7, 2011, at 7:49 AM, Tom Van Cutsem wrote: But again, I would hope that an implementation that supports both Object.freeze + proxies just supports freezing proxies via the fix() trap as per the draft spec. I don't see the need for such an

value proxies, fundamental traps for binary operators, precedence

2011-04-08 Thread Claus Reinke
I finally got a first look at the 'Virtual Values for Language Extension' paper referred to in the value proxies strawman [1], and suddenly find value proxies more interesting. Somehow the term proxy never suggested to me that this would allow for user-defined infix operators - perhaps a wiki

Re: Flattening syntactic tail nests (paren-free, continued)

2011-04-08 Thread Claus Reinke
In my previous post, I suggested tail nests as a profitable target for reducing reducing parens and braces that distract from common code patterns. I made two concrete suggestions, to make both braces around function bodies and parens around function applications optional. The combination of

Re: Parameter lists as arguments destructuring sugar

2011-04-08 Thread Sean Eagan
Actually, forget about desugaring. Here is a refined set of proposals to replace what's above: Define parameter lists in terms of array destructuring: === Why: Parameter lists already perform limited destructuring of function

Re: Parameter lists as arguments destructuring sugar

2011-04-08 Thread Bob Nystrom
I've implemented an unrelated language that works this way, and it is really nice, but I don't know if moving ES to that after the fact would work. But maybe I'm misreading your proposal. Consider: function show(a, b, c) { log(a + | + b + | + c); } var arg = [1, 2, 3]; show(arg);

Re: ECMAScript Object equivalence classes proposal

2011-04-08 Thread P T Withington
On 2011-04-07, at 13:27, Brendan Eich wrote: On Apr 5, 2011, at 2:19 PM, David Bruant wrote: What I'm worried about is the memory cost of such an implementation. The current [[HasInstance]] implementation has a constant memory cost. Keeping references has a linear memory cost in terms of

Re: ECMAScript Object equivalence classes proposal

2011-04-08 Thread Allen Wirfs-Brock
On Apr 8, 2011, at 11:40 AM, P T Withington wrote: An oldie, but a goodie, perhaps relevant to this discussion: http://www.cs.purdue.edu/homes/jv/pubs/oopsla97.pdf Absolutely! We used this technique quite effectively in Instantiations' Jove whole program optimizer for Java

Re: ECMAScript Object equivalence classes proposal

2011-04-08 Thread David Bruant
Le 07/04/2011 19:27, Brendan Eich a écrit : On Apr 5, 2011, at 2:19 PM, David Bruant wrote: What I'm worried about is the memory cost of such an implementation. The current [[HasInstance]] implementation has a constant memory cost. Keeping references has a linear memory cost in terms of