> > I like the idea of a special syntactic form a lot. One of the nice things > about `constructor` is that it's easy to explain "you [[Construct]] with > the constructor". We can't use `call` similarly any more, but I totally > agree something like it would be pretty nice. >
Unfortunately, we can't use a magic method name. Just to throw out a couple of other ideas though: Parens sans method name: class C { constructor() { /* new me */ } () { /* call me */ } } Contextual keyword after constructor: class C { constructor() { /* new me */ } constructor call() { /* call me */ } } With a "dot" instead: class C { constructor() { /* new me */ } constructor.call() { /* call me */ } }
_______________________________________________ es-discuss mailing list es-discuss@mozilla.org https://mail.mozilla.org/listinfo/es-discuss