Re: standardizing Error.stack or equivalent

2014-03-26 Thread Christian Plesner Hansen
Just curious: do you have any particular parts of #1 in mind that could be simplified? c On Tue, Mar 25, 2014, at 01:49 PM, Mark S. Miller wrote: Not only would I hope for all of this in ES7, I would add 5) sourcemaps 6) sourcemap extension to template strings, as in that old email 7)

[[Set]] and inherited readonly data properties

2014-03-26 Thread Jason Orendorff
use strict; function Pony() {} Object.freeze(Object.prototype); Pony.prototype.toString = function () { return Pony; }; The last line here throws a TypeError in ES5 and ES6.* Can we change it? To me, it stands to reason that you should be able to freeze Object.prototype and not

Re: [[Set]] and inherited readonly data properties

2014-03-26 Thread David Bruant
Le 26/03/2014 19:24, Jason Orendorff a écrit : use strict; function Pony() {} Object.freeze(Object.prototype); Pony.prototype.toString = function () { return Pony; }; The last line here throws a TypeError in ES5 and ES6.* Can we change it? To me, it stands to reason that

Re: [[Set]] and inherited readonly data properties

2014-03-26 Thread Allen Wirfs-Brock
On Mar 26, 2014, at 11:24 AM, Jason Orendorff wrote: use strict; function Pony() {} Object.freeze(Object.prototype); Pony.prototype.toString = function () { return Pony; }; The last line here throws a TypeError in ES5 and ES6.* Can we change it? To me, it stands to reason

Re: [[Set]] and inherited readonly data properties

2014-03-26 Thread Mark S. Miller
This mistake is my single biggest regret from the ES5 days. We had a chance to get this right when it would have been rather painless and we blew it. Although it can no longer be fixed without a lot of pain, I still think the pain of not fixing it will be greater. However, I'm sick of arguing

Re: [[Set]] and inherited readonly data properties

2014-03-26 Thread Brendan Eich
Mark S. Miller wrote: This mistake is my single biggest regret from the ES5 days. We had a chance to get this right when it would have been rather painless and we blew it. Indeed, as JSC and (therefore, at the time it was copying semantics) V8 did implement a fix to the override mistake.

Re: [[Set]] and inherited readonly data properties

2014-03-26 Thread Andrea Giammarchi
I am not sure I understood: is not throwing and a silent failure preferred? 'cause that method won't be there anyway... I need to write chapter 3 of my quadrilogy of posts related to descriptors and inheritance* but you can simply avoid that problem via `Object.defineProperty(Pony.prototype,

Re: [[Set]] and inherited readonly data properties

2014-03-26 Thread Andrea Giammarchi
actually `writable:false` is OK, it's only the `get` case that is buggy, as well as `set` on Android 2.3.6 (or lower) you can [try this page]( http://www.3site.eu/jstests/configurable.html) which will show an alert like ``` 4, // the length true, // has enumerable bug OK, // code works

article on ES6 and Traceur

2014-03-26 Thread Mark Volkmann
Here's an article I wrote recently that may be of interest. It covers automating the use of Traceur to generate ES5 code. http://sett.ociweb.com/sett/settApr2014.html -- R. Mark Volkmann Object Computing, Inc. ___ es-discuss mailing list