super constructor calls for max/min classes

Allen Wirfs-Brock allen at wirfs-brock.com
Tue Jul 10 14:05:09 PDT 2012


On Jul 10, 2012, at 12:16 PM, Erik Arvidsson wrote:

> 1) I'm in favor in principal.
> 
> We just need to work out the details here. Is it really only Object
> that has issues? Aren't all the existing "classes" problematic since
> they can be called instead of constructed?


I address some of these issues in http://wiki.ecmascript.org/doku.php?id=strawman:subclassable-builtins (which I really need to finish up a few loose ends)



> 
> class MyError extends Error {}
> 
> Error.call(this) returns a new Error object.
> 
> 2) Leave it to the linters.
> 
> -- 
> erik
> 

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.mozilla.org/pipermail/es-discuss/attachments/20120710/6d3b8300/attachment.html>


More information about the es-discuss mailing list