3 ms·
Wow: * 2C. Syntactic Extensions. The user shall not be able to modify the source language syntax. In particular the user shall not be able to introduce new pre
by twic 13y ago
Wow:
* 2C. Syntactic Extensions. The user shall not be able to modify the source language syntax. In particular the user shall not be able to introduce new precedence rules or to define new syntactic forms.*
Sounds like somebody had had a bad time with LISP at some point. Or maybe the point of that requirement is to combine with this one:
* 1E. Simplicity. The language should not contain unnecessary complexity. It should have a consistent semantic structure that minimizes the number of underlying concepts. It should be as small as possible consistent with the needs of the intended applications. It should have few special cases and should be composed from features that are individually simple in their semantics. The language should have uniform syntactic conventions and should not provide several notations for the same concept. No arbitrary restriction should be imposed on a language feature.*
To make LISP programmers explode with outrage.
Joking aside, requirement 2C sounds good to me. Having dealt with macros in a few languages, and DSLs in Ruby, i'm not convinced they carry their weight in the long run.
Nitpick:
5E. Initial Values. There shall be no default initial-values for variables.
Java: partial. Java defines initial values for all types, though recommends against using them and Java compilers attempt to warn of such use.
Eh, no. Local variables don't get initial values, and you can't read from them before their first definite assignment. Fields in objects get initial values, and i'm not aware of any standard recommendation against, or compiler warning for, their use.
That said, common best practice these days is to declare fields final, which means they get vaguely similar semantics to local variables - they have to be assigned values in the constructor (or their declaration, or an instance initialiser), and they can't be read from in the constructor before that assignment. The minor difference is that if the constructor calls an instance method, that instance method can refer to uninitialised final fields. It should be noted that although the compiler allows this, Joshua Bloch doesn't, and if you do it, he will come to your house and beat you with a sock full of billiard balls.