Alternative syntax for <|
dherman at mozilla.com
Thu Nov 17 14:05:51 PST 2011
On Nov 17, 2011, at 10:17 AM, Jason Orendorff wrote:
> I'm with Allen. If ES classes can contain any initialization code, I
> think it should run in program order, interleaved with top-level
> statements. Anything else is just confusing.
This is a great point, which I'd overlooked (not sure if Allen already said that and I missed it). But I'm not sure whether it argues for no declarative classes, for no syntax for statics, or for a restricted syntax for statics (e.g., only static methods).
> Note that classdefs in Ruby and Python aren't hoisted, and nobody
> complains. In those languages classdefs very often contain procedural
> code, for many purposes.
Good comparison, thanks. More grist...
More information about the es-discuss