If It's Going To Be Full Closures Or Dead Java, I Choose...
... full closures, as in BGGA, because the prospect of Java dying will be a really hard pill to swallow.
I realize this is a switching of sides of some sort, as I was saying the opposite just 30 days ago.
And quite frankly, Mr. Gafter scared me into his side:
Neal Gafter: Personally, I believe rumors of Java's demise are greatly exaggerated. We should think of Java as a living language, and strive to eliminate much of the accidental complexity of Java programs. I believe it is worth adding support for closures and control abstraction, to reduce such complexity of both the sequential and concurrent aspects of our programs. At the same time, for completely new code bases, we should also consider (and continue to develop) newer languages such as Scala, which benefit from the lessons of Java.
The thinking behind my switching of sides is simple, and non-technical. While many evaluate the various proposals based solely on their technical merits, I base my decision on the roles people play in the Java ecosystem.
It's one thing for an outsider such as Bruce Tate, or even Bruce Eckel to run around saying Java is dead. It's something completely different for Mr. Javac (I still think of Neal Gafter as Mr. Javac) to say the same thing.
Have you seen the stream of people leaving the Java development team, be they program managers, lead developers, or evangelists? This happened after every major release of Java, starting with JDK 1.1. Sure you can always hire new people to fill the old roles, but it's not the same. They have different visions, styles, and agendas.
The bottom line, for me at least, is that we should not bite the hands that feed us. For the day when the last JDK developer leaves the room, Java is truly dead.
Please, Uncle Neal, give us closures. "And we shall like them!"
Re: If It's Going To Be Full Closures Or Dead Java, I Choose...
Re: If It's Going To Be Full Closures Or Dead Java, I Choose...
Josh Bloch won me over in his Javapolis talk. I was especially effected by his comparison to Generics. While Pizza had served as a multi-year test of the feature before it was released, last minute changes (wildcards) were added without being tested by the industry, causing many problems people have with generics.
If multiple implementations of closures can be tested for a year or two by the public, I would feel comfortable with it being added to Java. Adding a feature like this to Java 7, just for the sake of keeping up with experimental languages like Scala, and dynamic languages where closures have been commonplace, is just reckless.
Had Java jumped for every new language feature as they had come along, we would all be scratching our heads trying to figure out what use our Java 1.4 Aspects for. Instead, Java has always been a much more mature language, adopting best of breed features from other languages (until Java 5, of course).
I don't understand why people need Java to have all these feature. Just pull another language out of the toolbox, if that's what you need. I guess, if all you have is a hammer, you want to make sure that hammer has a built-in screwdriver.