>> ```js
>> class MySuperClass {}
>>
>> // This function assumes that MySuperClass is an ES5 constructor function
>> function MySubConstructor(foo) {
>> MySuperClass.call(this);
>> this.foo = foo;
>> }
>> MySubConstructor.prototype = Object.create(MySuperClass.prototype);
>> MySubConstructor.prototype.constructor = MySubConstructor;
>> ```
>
> so if MySuperCall didn’t have the throw on [[Call]] behavior the above would
> work just fine.
In general, I’d expect this kind of subclassing to fail, due to the new
instantiation protocol. Wrong?
--
Dr. Axel Rauschmayer
[email protected]
rauschma.de
_______________________________________________
es-discuss mailing list
[email protected]
https://mail.mozilla.org/listinfo/es-discuss