Re: Feedback on Read-only Override Prohibition is [not a mistake]

2012-01-15 Thread Allen Wirfs-Brock
On Jan 15, 2012, at 8:10 AM, David Bruant wrote: Hi, I'm refering to Allen's writing at [1]: The basic idea is that the properties prototype object are shared parts of all of inheriting child object. Modifying such a shared part by a child, introduces a local change that is visible to

Re: Feedback on Read-only Override Prohibition is [not a mistake]

2012-01-15 Thread David Bruant
Le 15/01/2012 20:21, Allen Wirfs-Brock a écrit : On Jan 15, 2012, at 8:10 AM, David Bruant wrote: Hi, I'm refering to Allen's writing at [1]: The basic idea is that the properties prototype object are shared parts of all of inheriting child object. Modifying such a shared part by a child,

Re: Feedback on Read-only Override Prohibition is [not a mistake]

2012-01-15 Thread David Bruant
Le 15/01/2012 21:23, David Bruant a écrit : - function C(){ this.length = 3; } function f(a,b){} C.prototype = f; var c = new C(); console.log(c.length); - For this code, ECMAScript 5 says: When doing new C(), |this| is assigned C.prototype which is the function f (it

Re: Feedback on Read-only Override Prohibition is [not a mistake]

2012-01-15 Thread David Bruant
Le 15/01/2012 21:23, David Bruant a écrit : - function C(){ this.length = 3; } function f(a,b){} C.prototype = f; var c = new C(); console.log(c.length); - For this code, ECMAScript 5 says: When doing new C(), |this| is assigned C.prototype which is the function f (it