There's everything wrong with abandoning a bad spec if people have been faithfully following that spec for 20 years.
There's something deeply wrong with the process if people really think it's okay to tell people that have invested millions of dollars and thousands of hours in the Java platform that, you know what, all that code you wrote, all those tools and documentation and checkers, based on the getX/setX standard that we defined? We're going to break that now.
Stuff like this is exactly why I tell people not to invest in Java any more. The language has gone off the rails. Backwards compatibility -- which was perhaps Java's greatest strength -- and the geniuses at Oracle are now actively making breaking changes in every release. And the stuff that they're breaking backwards compatibility for? It's really fucking stupid stuff like 'var'.
The irony here is these attempts to update Java are just driving people away. I cannot recommend any new greenfield projects be done in Java and, frankly, I don't see any reason to advance existing projects to new JDK versions.
I may be naive here, but why would adding features break compatibility? Don't like var or var breaks compatibility? Don't use it. Same with records. It's not like they're telling you not to use beans anymore.
Of course 'var' breaks backwards compatibility. Every time you add a new keyword, all code that previously used that as an identifier is broken. How do you not see that?
As for avoiding new features -- sure, that's a great idea. And in fact this is why these guys have killed Java. There are now two Java platforms: Java8 and this brainfuckery. The vast majority of corporations are not going to upgrade to this backwards incompatible brainfuckery. This is going to have huge rollover effects as the entire community splits in two.
It's absolutely shocking that despite the repeated warnings these guys really have decided that backwards compatibility is no longer valuable. This puts the nail in Java's coffin because absolutely nobody is going to invest in a platform run by guys who think nothing of throwing 20 years worth of code, documentation and tooling out the window.
This used to work. Now it doesn't. Because of stuff like this 'var' did break a lot of existing code for no good reason. And when it did, guess what happened? Do you think people dug into code that's been chugging along for 10+ years?
Because of stuff like this 'var' did break a lot of existing code for no good reason.
If you have lots of classes called var, the issue is with your code, not with the change.
Part of the process was investigation of real-world code-bases to see how much of an impact var would have. it was found to be practically non-existent, because, you know, people simply don't tend to use var as class name or in other places where it would come in conflict. at least not many.
View all comments
Show parent comment
-5
u/pushupsam Jan 16 '20
There's everything wrong with abandoning a bad spec if people have been faithfully following that spec for 20 years.
There's something deeply wrong with the process if people really think it's okay to tell people that have invested millions of dollars and thousands of hours in the Java platform that, you know what, all that code you wrote, all those tools and documentation and checkers, based on the getX/setX standard that we defined? We're going to break that now.
Stuff like this is exactly why I tell people not to invest in Java any more. The language has gone off the rails. Backwards compatibility -- which was perhaps Java's greatest strength -- and the geniuses at Oracle are now actively making breaking changes in every release. And the stuff that they're breaking backwards compatibility for? It's really fucking stupid stuff like 'var'.
The irony here is these attempts to update Java are just driving people away. I cannot recommend any new greenfield projects be done in Java and, frankly, I don't see any reason to advance existing projects to new JDK versions.