Re: ES6,ES7,ES8 and beyond. A Proposed Roadmap.

2013-04-21 Thread Andrea Giammarchi
not sure I understand those examples, but the moment a developer starts yelding everything, is the moment all non-blovking asynchronous advantages are gone 'cause you are waiting instead of keep doing the rest, isn't it? On Sat, Apr 20, 2013 at 9:56 PM, Domenic Denicola

Re: Modules: Curly Free

2013-04-21 Thread Claus Reinke
Anonymous export is simply about allowing library authors to indicate a module's main entry point. Semantically, we're talking about the difference between a string and a symbol; syntactically, we're talking about one production. It's all cleanly layered on top of the rest of the system. Let's

Re: B.3.1 The __proto__ pseudo property

2013-04-21 Thread David Bruant
Hi Axel, Le 21/04/2013 01:37, Axel Rauschmayer a écrit : __proto__ can be globally switched off by deleting Object.prototype.__proto__. I'm assuming that that is useful for security-related applications (Caja et al.). But I'm wondering: doesn't that go too far? I'm seeing three ways of using

Re: ES6,ES7,ES8 and beyond. A Proposed Roadmap.

2013-04-21 Thread Sam Tobin-Hochstadt
On Sun, Apr 21, 2013 at 12:21 AM, Mark S. Miller erig...@google.com wrote: I hesitate to put Module Loaders on the above list rather than leaving them in ES6; but it would allow their semantics to rest on event loops and their API to rest on promises. If we can get ES7 out quickly, this need

Re: ES6,ES7,ES8 and beyond. A Proposed Roadmap.

2013-04-21 Thread Sam Tobin-Hochstadt
On Sun, Apr 21, 2013 at 12:56 AM, Domenic Denicola dome...@domenicdenicola.com wrote: Finally, I know a lot of people, myself included, are excited about `await` sugar. That is, the plan would be to use generators + promises in ES6 with the awkwardness that entails; once we know what the

Re: ES6,ES7,ES8 and beyond. A Proposed Roadmap.

2013-04-21 Thread Bjoern Hoehrmann
* Andrea Giammarchi wrote: not sure I understand those examples, but the moment a developer starts yelding everything, is the moment all non-blovking asynchronous advantages are gone 'cause you are waiting instead of keep doing the rest, isn't it? A simple example would be an application running

Re: ES6,ES7,ES8 and beyond. A Proposed Roadmap.

2013-04-21 Thread Bjoern Hoehrmann
* Sam Tobin-Hochstadt wrote: I don't see what the point of `await` is in your gist. It looks like all of the work is being done by `function^`, which looks to be sugar for creating a function and passing it to a scheduler like `Q.async` or `taskjs.spawn`. We could add that sugar if we wanted,

Re: ES6,ES7,ES8 and beyond. A Proposed Roadmap.

2013-04-21 Thread Sam Tobin-Hochstadt
On Sun, Apr 21, 2013 at 9:20 AM, Bjoern Hoehrmann derhoe...@gmx.net wrote: * Sam Tobin-Hochstadt wrote: I don't see what the point of `await` is in your gist. It looks like all of the work is being done by `function^`, which looks to be sugar for creating a function and passing it to a scheduler

Re: ES6,ES7,ES8 and beyond. A Proposed Roadmap.

2013-04-21 Thread Bjoern Hoehrmann
* Sam Tobin-Hochstadt wrote: On Sun, Apr 21, 2013 at 9:20 AM, Bjoern Hoehrmann derhoe...@gmx.net wrote: * Sam Tobin-Hochstadt wrote: I don't see what the point of `await` is in your gist. It looks like all of the work is being done by `function^`, which looks to be sugar for creating a function

Re: B.3.1 The __proto__ pseudo property

2013-04-21 Thread Allen Wirfs-Brock
On Apr 20, 2013, at 4:37 PM, Axel Rauschmayer wrote: __proto__ can be globally switched off by deleting Object.prototype.__proto__. I’m assuming that that is useful for security-related applications (Caja et al.). But I’m wondering: doesn’t that go too far? I’m seeing three ways of using

Re: B.3.1 The __proto__ pseudo property

2013-04-21 Thread Allen Wirfs-Brock
On Apr 21, 2013, at 5:22 AM, David Bruant wrote: Hi Axel, Le 21/04/2013 01:37, Axel Rauschmayer a écrit : __proto__ can be globally switched off by deleting Object.prototype.__proto__. I’m assuming that that is useful for security-related applications (Caja et al.). But I’m wondering:

Re: Modules: Curly Free

2013-04-21 Thread Brendan Eich
No. /be Claus Reinke wrote: Anonymous export is simply about allowing library authors to indicate a module's main entry point. Semantically, we're talking about the difference between a string and a symbol; syntactically, we're talking about one production. It's all cleanly layered on top of

Re: ES6,ES7,ES8 and beyond. A Proposed Roadmap.

2013-04-21 Thread David Herman
On Apr 20, 2013, at 9:21 PM, Mark S. Miller erig...@google.com wrote: * Communicating Event Loop concurrency model, - with the two-priority event loop already required by both browser and server. * Object.observe * Distribution compatible promises (at least Promises/A+) *

Re: Modules: Curly Free

2013-04-21 Thread Brendan Eich
Sorry, let me say a bit more. You identified the entry-point idea. Good so far. But then you went too far and made that entry-point, which with anonymous export is often (but not always) a function, with the body of the module, its top-level code. A module is not a function. It is not

Re: Modules: Curly Free

2013-04-21 Thread Brendan Eich
Brendan Eich wrote: But then you went too far and made that entry-point, which with anonymous export is often (but not always) a function, with s/with/be/ the body of the module, its top-level code. /jetlagged-be ___ es-discuss mailing list

Re: B.3.1 The __proto__ pseudo property

2013-04-21 Thread Brendan Eich
Allen Wirfs-Brock wrote: On Apr 21, 2013, at 5:22 AM, David Bruant wrote: Hi Axel, Le 21/04/2013 01:37, Axel Rauschmayer a écrit : __proto__ can be globally switched off by deleting Object.prototype.__proto__. I’m assuming that that is useful for security-related applications (Caja et al.).

Re: ES6,ES7,ES8 and beyond. A Proposed Roadmap.

2013-04-21 Thread Brendan Eich
Domenic Denicola wrote: This looks lovely. The only thing I'd want to add: we need integers! And generally better numeric types. From speaking to developers on the ground, this is the biggest missing language feature they see (that isn't already addressed in ES6). I know Brendan has made

class-private syntax in ES6 (was: ES6, ES7, ES8 and beyond. A Proposed Roadmap.)

2013-04-21 Thread Brendan Eich
Trimming cc: list to just es-discuss. Mark S. Miller wrote: * Completing the class design - at least high integrity and private state If I'm not mistaken, we need class-private syntax for classes to have ultimate double-blind consensus in *ES6*. See last meeting notes. At JQueryUK,

Re: B.3.1 The __proto__ pseudo property

2013-04-21 Thread David Herman
On Apr 21, 2013, at 8:55 AM, Allen Wirfs-Brock al...@wirfs-brock.com wrote: Deleting Object.prototype.__proto__ will not be be specified as disabling {__proto__: foo}. Was that what we'd agreed to? I hadn't remembered that. I don't like it because it's special-case syntax, but I can also

Re: B.3.1 The __proto__ pseudo property

2013-04-21 Thread Andrea Giammarchi
you can hot-swap the chain, something Object.create() cannot do so it is much more powerful, unless things changed that much lately ... On Sun, Apr 21, 2013 at 11:03 AM, David Herman dher...@mozilla.com wrote: On Apr 21, 2013, at 8:55 AM, Allen Wirfs-Brock al...@wirfs-brock.com wrote:

Re: B.3.1 The __proto__ pseudo property

2013-04-21 Thread Brendan Eich
David Herman wrote: On Apr 21, 2013, at 8:55 AM, Allen Wirfs-Brockal...@wirfs-brock.com wrote: Deleting Object.prototype.__proto__ will not be be specified as disabling {__proto__: foo}. Was that what we'd agreed to? I think what Allen means is, whether or not there's a magic

Re: B.3.1 The __proto__ pseudo property

2013-04-21 Thread Allen Wirfs-Brock
On Apr 21, 2013, at 11:03 AM, David Herman wrote: On Apr 21, 2013, at 8:55 AM, Allen Wirfs-Brock al...@wirfs-brock.com wrote: Deleting Object.prototype.__proto__ will not be be specified as disabling {__proto__: foo}. Was that what we'd agreed to? I hadn't remembered that. I don't like

Re: B.3.1 The __proto__ pseudo property

2013-04-21 Thread Brendan Eich
Allen Wirfs-Brock wrote: On Apr 21, 2013, at 10:03 AM, Brendan Eich wrote: Allen Wirfs-Brock wrote: This isn't what we seemed to agree on at past TC39 meetings. It's also not what the engines trying to converge on ES6 semantics have implemented. It's not clear to me, yet what convergence we

Re: B.3.1 The __proto__ pseudo property

2013-04-21 Thread Allen Wirfs-Brock
On Apr 21, 2013, at 11:12 AM, Brendan Eich wrote: David Herman wrote: On Apr 21, 2013, at 8:55 AM, Allen Wirfs-Brockal...@wirfs-brock.com wrote: Deleting Object.prototype.__proto__ will not be be specified as disabling {__proto__: foo}. Was that what we'd agreed to? I think what

Re: B.3.1 The __proto__ pseudo property

2013-04-21 Thread Brendan Eich
Allen Wirfs-Brock wrote: On Apr 21, 2013, at 11:12 AM, Brendan Eich wrote: David Herman wrote: On Apr 21, 2013, at 8:55 AM, Allen Wirfs-Brockal...@wirfs-brock.com wrote: Deleting Object.prototype.__proto__ will not be be specified as disabling {__proto__: foo}. Was that what we'd agreed

Re: B.3.1 The __proto__ pseudo property

2013-04-21 Thread Brendan Eich
Brendan Eich wrote: Allen Wirfs-Brock wrote: On Apr 21, 2013, at 11:12 AM, Brendan Eich wrote: David Herman wrote: On Apr 21, 2013, at 8:55 AM, Allen Wirfs-Brockal...@wirfs-brock.com wrote: Deleting Object.prototype.__proto__ will not be be specified as disabling {__proto__: foo}. Was

Re: B.3.1 The __proto__ pseudo property

2013-04-21 Thread Andrea Giammarchi
V8 already poisons when getOwnPropertyDescriptor has a setter and this setters is the __proto__ one: https://code.google.com/p/v8/source/browse/trunk/src/v8natives.js#390 This means V8 always throws and does not preserve the same realm, if I understand what that means:

Re: B.3.1 The __proto__ pseudo property

2013-04-21 Thread Allen Wirfs-Brock
On Apr 21, 2013, at 11:53 AM, Brendan Eich wrote: Allen Wirfs-Brock wrote: ... This is specified by ES5, already. Doesn't matter because what ES5 specifies is already incompatible with web reality when the property name is __proto__. No. Browsers implementing ES5 and de-facto

Re: B.3.1 The __proto__ pseudo property

2013-04-21 Thread Andrea Giammarchi
Allen that's correct/expected ... as __proto__ is own in the Object.prototype only or am I missing something? On Sun, Apr 21, 2013 at 12:21 PM, Allen Wirfs-Brock al...@wirfs-brock.comwrote: On Apr 21, 2013, at 11:53 AM, Brendan Eich wrote: Allen Wirfs-Brock wrote: ... This is specified

Re: B.3.1 The __proto__ pseudo property

2013-04-21 Thread Allen Wirfs-Brock
On Apr 21, 2013, at 12:05 PM, Brendan Eich wrote: What I mean is that: let obj = {__proto__: null} will always create an object whose [[Prototype]] Didn't you mean an object whose property named '__proto__' here? is null. Regardless of whether or not anybody has done: delete

Re: B.3.1 The __proto__ pseudo property

2013-04-21 Thread Brendan Eich
Allen Wirfs-Brock wrote: On Apr 21, 2013, at 12:05 PM, Brendan Eich wrote: What I mean is that: let obj = {__proto__: null} will always create an object whose [[Prototype]] Didn't you mean an object whose property named '__proto__' here? is null. Regardless of whether or not anybody

Re: B.3.1 The __proto__ pseudo property

2013-04-21 Thread Andrea Giammarchi
for how much I love being ignored, I agree on Brendan, once deleted, which is an explicit action that means get this stuff out of my environment nothing else should be affected. If people would like to create enumerable/configurable/writable properties at runtime together with specific

Re: B.3.1 The __proto__ pseudo property

2013-04-21 Thread Axel Rauschmayer
However, let's get back to (a) coffee :-); (b) ES6 and the ability to delete Object.prototype.__proto__. You don't want that to affect object literals evaluated in the same realm after such a deletion. Why not? [Sorry for cutting in, but this is the core point of my confusion.] I’d

Re: B.3.1 The __proto__ pseudo property

2013-04-21 Thread Andrea Giammarchi
then you'll have ambiguous operations obj[key] = value; will not always do the same since obj[key] will not always do the same neither. If a program decides/needs/wants no magic then magic should disappear and if not in the chain it should not be inherited. I'd rather leave, if really

Re: B.3.1 The __proto__ pseudo property

2013-04-21 Thread Allen Wirfs-Brock
On Apr 21, 2013, at 12:31 PM, Brendan Eich wrote: Allen Wirfs-Brock wrote: On Apr 21, 2013, at 12:05 PM, Brendan Eich wrote: What I mean is that: let obj = {__proto__: null} will always create an object whose [[Prototype]] Didn't you mean an object whose property named '__proto__'

Re: B.3.1 The __proto__ pseudo property

2013-04-21 Thread Andrea Giammarchi
Apparently Axel can ... he wants the inherited from nowhere getter instead of passing through Object.getPrototypeOf(object) ... thing is Axel, if you can get rid of __proto__ in the Object.prototype, and that property simply disappears, you have all possibilities to redefine it as convenient as

Re: B.3.1 The __proto__ pseudo property

2013-04-21 Thread André Bargull
SpiderMonkey at least goes out of its way to do [[Set]] (let's call it) not [[DefineOwnProperty]] for 'o = {__proto__: 42}', so why wouldn't [[Set]] create a fresh property, seeing nothing on Object.prototype named '__proto__' with a setter to run? SpiderMonkey/JSC currently just use [[Set]]

Re: B.3.1 The __proto__ pseudo property

2013-04-21 Thread Axel Rauschmayer
Apparently Axel can ... he wants the inherited from nowhere getter instead of passing through Object.getPrototypeOf(object) ... thing is Axel, if you can get rid of __proto__ in the Object.prototype, and that property simply disappears, you have all possibilities to redefine it as

Re: B.3.1 The __proto__ pseudo property

2013-04-21 Thread Andrea Giammarchi
love it ... reminds me those days when [] or {} were invoking Array and Object in some env ... Anyway, I believe Allen is trying to say that {__proto__:whatever} should be spec'd as syntax, regardless what will be of the Object.prototype.__proto__ property/descriptor so that you can get rid of it

Re: B.3.1 The __proto__ pseudo property

2013-04-21 Thread Brendan Eich
Allen Wirfs-Brock wrote: On Apr 21, 2013, at 12:31 PM, Brendan Eich wrote: You don't want that to affect object literals evaluated in the same realm after such a deletion. Why not? Why should it? ... because it did in ES5-conforming implementations that support __proto__ as a de-facto

Re: Modules: Curly Free

2013-04-21 Thread Claus Reinke
But then you went too far and made that entry-point, which with anonymous export is often (but not always) a function, with the body of the module, its top-level code. I suggested that modules be callable, executing the module body and returning what would be the anonymous export. I did not

Re: B.3.1 The __proto__ pseudo property

2013-04-21 Thread Olov Lassus
2013/4/21 Allen Wirfs-Brock al...@wirfs-brock.com Also note that JSON.parse('{__proto__: null}') does not create an object whose [[Protoype]] is null because JSON.parse uses [[DefineOwnProperty]] to create all its properties so this will just result in an own property whose value is null.

Re: ES6,ES7,ES8 and beyond. A Proposed Roadmap.

2013-04-21 Thread David Bruant
Le 21/04/2013 19:09, Brendan Eich a écrit : Domenic Denicola wrote: Doing a quick poll of some IRC rooms, there's some call for shared-memory multithreading. I know this was a concern of the asm.js project, or more generally for the JS-as-a-compilation-target mission. I don't think this is a

Re: B.3.1 The __proto__ pseudo property

2013-04-21 Thread Andrea Giammarchi
agreed for consistency too, once deleted, the magic should disappear 100% reality will be that most devs won't delete it so I don't see concrete side effects out there. However, this is how I would spec it (or better, how I would drop the axe accepting a compromise for this property)

Re: B.3.1 The __proto__ pseudo property

2013-04-21 Thread Andrea Giammarchi
apologies, I've realized SES might want more something like this: (function(getOwnPropertyDescriptor){ Object.defineProperty( Object, 'getOwnPropertyDescriptor', { enumerable: false, configurable: false, writable: false, value: function(object, property) {

Re: B.3.1 The __proto__ pseudo property

2013-04-21 Thread Mark S. Miller
On Sun, Apr 21, 2013 at 1:37 PM, Brendan Eich bren...@mozilla.com wrote: Allen Wirfs-Brock wrote: On Apr 21, 2013, at 12:31 PM, Brendan Eich wrote: You don't want that to affect object literals evaluated in the same realm after such a deletion. Why not? Why should it? ... because it

Re: B.3.1 The __proto__ pseudo property

2013-04-21 Thread Andrea Giammarchi
Off Topic: it's really funny that it took 10 years to teach people how inheritance works in JS and today there's some legacy that instead of constructors uses their objects or just objects as prototype so that {__proto__:whatever} is considered a used pattern. If the most common case is

Re: B.3.1 The __proto__ pseudo property

2013-04-21 Thread Mark S. Miller
Warning: The following is a sickening idea. I would really hate to see us do it. But I feel obliged to post it as it may in fact be the right thing to do. Given: Web reality drives us towards recognizing {, __proto__: , } as special syntax for initializing [[Prototype]]. Given:

Re: B.3.1 The __proto__ pseudo property

2013-04-21 Thread Andrea Giammarchi
that won't work? __proto__ in {__proto__:{}}; // true __proto__ in {__proto__:{}}; // still true, since __proto__ in Object.prototype, unless deleted am I wrong? On Sun, Apr 21, 2013 at 3:27 PM, Mark S. Miller erig...@google.com wrote: Warning: The following is a sickening idea. I would

Re: ES6,ES7,ES8 and beyond. A Proposed Roadmap.

2013-04-21 Thread Kevin Gadd
For some subset of use cases I imagine shared-memory multithreading being limited to immutable objects could do the trick. Of course, I don't know if real immutability is actually possible in ES as currently specified - if I called Object.freeze or Object.seal on a JS object would it actually be

Re: B.3.1 The __proto__ pseudo property

2013-04-21 Thread Andrea Giammarchi
uh wait ... you meant ... uh ... wait, sorry, OK :D so {__proto__:Array.prototype} is an instanceof Array {__proto__:Array.prototype} is an object with a __proto__ property that points to Array.prototype which means that __proto__ is magically overwritten ... yak?! On Sun, Apr 21, 2013 at

Re: B.3.1 The __proto__ pseudo property

2013-04-21 Thread Andrea Giammarchi
that said, I like the dual behavior if not because there's no way even by accident somebody can change a prototype chain in a for/in loop var copied = {__proto__:null,__proto__:Array.prototype}; var copy = {}; for (var key in copied) { if (copied.hasOwnProperty(key)) { copy[key] =

Re: ES6,ES7,ES8 and beyond. A Proposed Roadmap.

2013-04-21 Thread Kevin Gadd
isn't typeof (console.log) function and not object? by object I meant an Object object, not 'any arbitrary JS value'. I suppose the distinction is really blurry, and you would still have to deal with problems like the object's prototype chain containing callables... On Sun, Apr 21, 2013 at 3:42

Re: ES6,ES7,ES8 and beyond. A Proposed Roadmap.

2013-04-21 Thread Sam Tobin-Hochstadt
Then consider `Object.freeze(console)`. Fundamentally, frozen objects are not appropriate for prohibiting shared state. Sam On Sun, Apr 21, 2013 at 6:44 PM, Kevin Gadd kevin.g...@gmail.com wrote: isn't typeof (console.log) function and not object? by object I meant an Object object, not 'any

Re: B.3.1 The __proto__ pseudo property

2013-04-21 Thread Brendan Eich
Mark S. Miller wrote: For all parties, some examples of legacy uses of {__proto__: }, whether hypothetical or observed, would help a lot. I doubt the stance special literal syntax for initializing [[Prototype]] without using either [[Put]]/[[Set]] nor [[DefineOwnProperty]] would be

Re: B.3.1 The __proto__ pseudo property

2013-04-21 Thread Allen Wirfs-Brock
On Apr 21, 2013, at 1:37 PM, Brendan Eich wrote: Allen Wirfs-Brock wrote: On Apr 21, 2013, at 12:31 PM, Brendan Eich wrote: You don't want that to affect object literals evaluated in the same realm after such a deletion. Why not? Why should it? ... because it did in ES5-conforming

Re: B.3.1 The __proto__ pseudo property

2013-04-21 Thread Mark S. Miller
We're not concerned if there is *any* such implementation. We care about the intersection of enough implementations that it becomes an issue for cross-browser code. And code that only works on one browser has been code that we've always[1] been willing to break going forward. [1] At least during

Re: B.3.1 The __proto__ pseudo property

2013-04-21 Thread Allen Wirfs-Brock
On Apr 21, 2013, at 3:11 PM, Mark S. Miller wrote: On Sun, Apr 21, 2013 at 1:37 PM, Brendan Eich bren...@mozilla.com wrote: Allen Wirfs-Brock wrote: On Apr 21, 2013, at 12:31 PM, Brendan Eich wrote: You don't want that to affect object literals evaluated in the same realm after such a

Re: B.3.1 The __proto__ pseudo property

2013-04-21 Thread Allen Wirfs-Brock
On Apr 21, 2013, at 3:27 PM, Mark S. Miller wrote: Warning: The following is a sickening idea. I would really hate to see us do it. But I feel obliged to post it as it may in fact be the right thing to do. Given: Web reality drives us towards recognizing {, __proto__: , }

Re: B.3.1 The __proto__ pseudo property

2013-04-21 Thread Mark S. Miller
On Sun, Apr 21, 2013 at 6:11 PM, Allen Wirfs-Brock al...@wirfs-brock.comwrote: On Apr 21, 2013, at 1:37 PM, Brendan Eich wrote: Allen Wirfs-Brock wrote: On Apr 21, 2013, at 12:31 PM, Brendan Eich wrote: You don't want that to affect object literals evaluated in the same realm after

Re: B.3.1 The __proto__ pseudo property

2013-04-21 Thread Mark S. Miller
On Sun, Apr 21, 2013 at 6:21 PM, Allen Wirfs-Brock al...@wirfs-brock.comwrote: On Apr 21, 2013, at 3:27 PM, Mark S. Miller wrote: Warning: The following is a sickening idea. I would really hate to see us do it. But I feel obliged to post it as it may in fact be the right thing to do.

Re: ES6,ES7,ES8 and beyond. A Proposed Roadmap.

2013-04-21 Thread Mark S. Miller
Agreed that Object.freeze does not give you what you need. RiverTrail already needs a kind of collection that is transitively immutable by construction. They need this for safe data parallelism. But the reason they are safe for parallel access within a vat/worker is the same reason they would be

Re: B.3.1 The __proto__ pseudo property

2013-04-21 Thread Andrea Giammarchi
On Sun, Apr 21, 2013 at 6:11 PM, Allen Wirfs-Brock al...@wirfs-brock.comwrote: We are free to specify a semantics that will make sense, now and for the long term. then, for the long term, if all I understood about this thing is that stinks for everybody, you should really consider to give

Re: B.3.1 The __proto__ pseudo property

2013-04-21 Thread Mark Miller
Hi Andrea, Allen's immediately previous sentence was The point is that I don't think there is any long standing behavior in this regard relating to object literals and deleting Object.prototype.__proto__ that the web is dependent upon. This sets the context for understanding Allen's next

Re: B.3.1 The __proto__ pseudo property

2013-04-21 Thread Brendan Eich
So as my last post said, if there's no observable difference in the field in switching from [[Put]] to [[SetInheritance]], then you and Mark are right, and we can do that in ES6 without fear of breaking any code. This change *is* observable in ES6, though. That's why I summoned Mark: to make

Re: B.3.1 The __proto__ pseudo property

2013-04-21 Thread Brendan Eich
Andrea may be asking for less than the standard someday removing __proto__, if I read him right. He's asking not to keep it indestructible, i.e., to make delete Object.prototype.__proto__ remove all the magic, including for 'o = {__proto__: p}'. But that seems to require using [[Put]]

Re: B.3.1 The __proto__ pseudo property

2013-04-21 Thread Brendan Eich
Again, you're inventing something new. Always risky, ignoring the throw-up-in-mouth effect :-|. Now the burden is on someone (who?) to find code on the web that uses the quoted form expecting the same results as the unquoted form, which is what all implementations I know of indeed provide.

Re: B.3.1 The __proto__ pseudo property

2013-04-21 Thread Mark S. Miller
On Sun, Apr 21, 2013 at 8:41 PM, Brendan Eich bren...@mozilla.com wrote: So as my last post said, if there's no observable difference in the field in switching from [[Put]] to [[SetInheritance]], then you and Mark are right, and we can do that in ES6 without fear of breaking any code. This

Re: B.3.1 The __proto__ pseudo property

2013-04-21 Thread Andrea Giammarchi
yep, I was asking to make it neutral 100% but that specific case, as written many replies before not only by me, seems to be reasonable, as long as delete Object.prototype.__proto__ is possible and, if this is possible, hoping that Object.getOwnPropertyDescriptor(Object.prototype, '__proto__').set

Re: B.3.1 The __proto__ pseudo property

2013-04-21 Thread Brendan Eich
Ok, so (after pushing back based on recorded consensus, which I think is fair), I'm ok with * Object.prototype.__proto__ is configurable. * o = {__proto__: p} semantics changes from ES5's [[Put]] to ES6's [[SetInheritance]]. I'm not sure everyone agrees, but let's assume these two. Why,

Re: B.3.1 The __proto__ pseudo property

2013-04-21 Thread Mark S. Miller
On Sun, Apr 21, 2013 at 8:45 PM, Brendan Eich bren...@mozilla.com wrote: Andrea may be asking for less than the standard someday removing __proto__, if I read him right. He's asking not to keep it indestructible, i.e., to make delete Object.prototype.__proto__ remove all the magic,

Re: B.3.1 The __proto__ pseudo property

2013-04-21 Thread Mark Miller
On Sun, Apr 21, 2013 at 9:42 PM, Brendan Eich bren...@mozilla.com wrote: Ok, so (after pushing back based on recorded consensus, which I think is fair), I'm ok with * Object.prototype.__proto__ is configurable. * o = {__proto__: p} semantics changes from ES5's [[Put]] to ES6's

Re: B.3.1 The __proto__ pseudo property

2013-04-21 Thread Andrea Giammarchi
if Object.getPrototypeOf() works there, how is that secret protected? In any case, do you agree since you can configure Object.prototype.__proto__ you could also poison it by your own instead of proposing an unusable poisoned setter as it is now in V8? I am talking about this possibility

Re: B.3.1 The __proto__ pseudo property

2013-04-21 Thread Mark S. Miller
On Sun, Apr 21, 2013 at 9:56 PM, Andrea Giammarchi andrea.giammar...@gmail.com wrote: if Object.getPrototypeOf() works there, how is that secret protected? Assuming the script does not make the object that the literal evaluates to available to the hostile environment it is running it. This

Re: B.3.1 The __proto__ pseudo property

2013-04-21 Thread Andrea Giammarchi
right now this is the V8 situation: https://code.google.com/p/v8/issues/detail?id=2645 which is different from SpiderMonkey one where you can: var protoSetter = Object.getOwnPropertyDescriptor( Object.prototype, '__proto__' ); delete Object.prototype.__proto__; // optionally var a = {}, b =

Re: B.3.1 The __proto__ pseudo property

2013-04-21 Thread Andrea Giammarchi
oh dear ... var protoSetter = Object.getOwnPropertyDescriptor( Object.prototype, '__proto__' ).set; // forgot the setter in previous example On Sun, Apr 21, 2013 at 10:07 PM, Andrea Giammarchi andrea.giammar...@gmail.com wrote: right now this is the V8 situation: