Hacker News new | ask | show | jobs
by bermanoid 5433 days ago
As it is, I have an unhealthy number of vim macros to deal with all the boilerplate that Java foists upon a developer.

I hate to bring up the editor wars thang, but knowing a lot of very skilled people in the Java world, I will say this: it's rare for a "best in class" Java developer to use anything but a full fledged Java IDE (not unheard of, but rare). If you're not using one of these (IntelliJ, Eclipse, or Netbeans, in my personal order of preference), you're really missing out on almost everything good that Java has to offer over other languages, as far as boilerplate-simplifying, integration, and bug-hunting. IMO, unless you're using a good Java IDE and have used it long enough to know it well, you are not actually coding Java, you're coding some shitty worst-of-all-worlds version of Java, and it's no surprise that you hate it. I don't know how I could possibly code Java and remain sane without the ten-times-a-minute ctrl-space auto-complete/lookup routine (along with all the other time saving macros and shortcuts that a good IDE will give you)...

FWIW, I say this as a die-hard emacs user (bite me, vim :) ) that uses it for damn near every "I have to edit some text" task that he comes across, so this is not an issue of me not understanding what a good text editor is capable of. Ruby, JS, PHP, Clojure, Python, and the like are in emacs territory for me, but when it comes to Java, the tools really do counteract many of the language's failures (and let's be honest, the number one offender is the lack of closures, with the annoyingly explicit static typing coming a close second), and I'll be honest, I miss the IDE features when I code dynamic languages - it sucks to have to resort to textual searches instead of actually walking the parse tree, even if it can get you 80% of the way there most of the time.

Honestly, I've always personally thought that AS3 had a lot of potential, as a mostly-statically-typed-but-dynamic-if-you-need-it version of Javascript, but even there the IDEs aren't quite up to the Java standard (mostly due to apathy, as far as I can tell, there's nothing about the language that would make any of the features common to Java IDEs any more difficult to implement in AS3 ones), so the benefits of the default static typing are somewhat muted...

1 comments

Sorry, I should have been more specific--I use Eclim to bring gvim inside the Eclipse environment, or I use Netbeans with a set of macros that parallel my vim ones. I find the built-in "boilerplate simplification" nonsense to be a patch over the fact that Java itself is no better than mediocre, and should not be considered a valid defense of Java as a tool.

And the reason? Because even with all these tools that have grown up around Java to address its shortcomings, it completely sucks. Absolutely sucks. Miserable to write and--more importantly--miserable to read. Meanwhile, I can comfortably write idiomatic Scala in Netbeans (the Eclipse plugin is shaky) with the editor's only help being Intellisense, idiomatic Scala that another programmer can read easily without trouble, because the language is geared toward actually being descriptive rather than covered in boilerplate.

And Scala is not a dynamically typed language, but shows that a static language can actually act very similarly to one. And you still get all those features that you miss. It's sort of what you're talking about re: AS3, but it's here now and works.

.

I wasn't joking earlier when I said that the best Java "tool" is a Scala compiler. It's not perfect (hello, long compile times), but I can do anything that I do in Java faster and with more readable and therefore reliable code in Scala. The reverse is not true, because to get around Java's inherent lack of expressivity you are forced to create new points of failure for yourself.

That's not good. It's not necessary. But it's defended to the death by people who--not you, but some of the other posters on this thread--really do truly think in Blub and don't understand why these things are bad.