| > No unsigned ints. I think that's a mixed blessing. I believe Java did this deliberately to avoid the trouble that C and C++ have with signed and unsigned integer types having to coexist. Personally I've never been inconvenienced by Java's lack of unsigned integer types, but I'm sure it can be annoying in some situations. I'm quite fond of Ada's approach to integer types, but I suspect I'm in a minority. > Silent integer overflow/wrap-around. It's not C- did it really have to copy this insanity? Curiously this cropped up 10 days ago. [0] You're not alone. The great John Regehr put it thus: [1] > Java-style wrapping integers should never be the default, this is arguably even worse than C and C++’s UB-on-overflow which at least permits an implementation to trap. > The fact that arrays got type variance wrong. At least Java has the defence that they didn't know how it would pan out. C# has no such excuse in copying Java. > No concept of `const` or immutability. I recall a Java wizard commenting that although a const system is the sort of feature that aligns with Java's philosophy, it's just too difficult to retrofit it. [0] https://news.ycombinator.com/item?id=26538842 [1] https://blog.regehr.org/archives/1401 |
It did, from http://www.gotw.ca/publications/c_family_interview.htm
> For me as a language designer, which I don't really count myself as these days, what "simple" really ended up meaning was could I expect J. Random Developer to hold the spec in his head. That definition says that, for instance, Java isn't -- and in fact a lot of these languages end up with a lot of corner cases, things that nobody really understands. Quiz any C developer about unsigned, and pretty soon you discover that almost no C developers actually understand what goes on with unsigned, what unsigned arithmetic is. Things like that made C complex. The language part of Java is, I think, pretty simple. The libraries you have to look up.
Since Java 8, the standard library has unsigned manipulation arithmetic classes, though.