Simplicity is a tradeoff that takes away power and control from the programmer and gives it to the computer. Computers don't need to be more powerful, programmers do. The tradeoff is a poor one and rarely worth the little gained.
In this case, what do we gain by not adding primitive value types in Java? The fact that you sleep better at night because the language is more "clean"? Why should we want that? Sleep is definitely important, but the idea that a language can be too complex is silly.
It does matter that new additions do remain consistent with the overall architecture, but there is no reason to advocate less features simply because you find the idea of learning something new disconcerting.
First, including features that you expect others (beginners) not to use is problematic. You can't really claim to know a language if you can't read other people's code when they are using standard language features. So you have to learn all those features whether you intend to use them or not. And learning them means knowing when and why they are used. Usually, this kind of stuff is just deferred to libraries and language extensions. (Haskell-style Langauge extensions and Python's future imports are a wonderful idea, I think.)
Second, people like to get comfortable in their languages. If the C language designers just said "Hey, er..., you know all these curly b's are unnecessary, let's drop 'em in the next standard," people wouldn't care for it. More features + more power + backwards compatibility can only carry you so far before it becomes downright unwieldy.
I don't think people learn very well that they should just forget everything they know every 5 years and start on mastering something completely new. The problem is not in the language being too complex (like you said,) but in our culture and habits. People don't like complexity. That's why we work so hard to make it go away.
import static spark.Spark.* ;
public class HelloWorld {
public static void main(String[] args) {
get("/hello", (req, res) -> "Hello World");
}
}This is more simple as written in previous version and is also consistent with it as it can be written in Java 7 (or earlier) like this.
import static spark.Spark.* ;
public class HelloWorld {
public static void main(String[] args) {
get("/hello", new Route() {
@Override
public Object handle(Request req, Response res)
throws Exception {
return "Hello World";
}
});
}
}You can see how closures in Java actually represent more familiar idea and by omitting unnecessary ceremony do make writing in it more simple.
Not about having "fewer" features.
Especially when Java is infantile in the small number of features it has...