News for hackers. Stuff that matters.
Re:Code faster with Intellij IDEA live templates by Cthulhu_ on Saturday January 18, 2014 @12:31PM (#7081488)
Could also be a subtle hint that the language in question (Java, Maven/XML) are too verbose. I mean, for dependencies and the like there's alternatives (for Java & co) in Gradle and SBT, or the very simple NPM and Bower formats; for build tools, see the same (and Grunt). There's no real benefit (anymore) to use XML for that kind of configuration.

Same with Java. Functional programming makes for much more expressive iteration than the iterator / for-loop pattern does, and it's much less verbose (think list.map(doSomething)).

Re:Code faster with Intellij IDEA live templates by pron on Saturday January 18, 2014 @03:33PM (#7082148)
Yes, but so what? Sometimes a little IDE love is a lot easier and more productive than changing your entire stack to use a different language/tool. Verbosity is a downside which might be more than offset by other upsides. It might certainly be beneficial to change your stack, but that's usually a very big decision that might have some serious and unforeseen consequences. Verbosity alone is rarely reason enough to make a switch.
Re:Code faster with Intellij IDEA live templates by jbrechtel on Sunday January 19, 2014 @10:57AM (#7084767)
Why the "Yeah, but so what?" rhetoric?

This is an important point, regardless. Sometimes new projects are started and it's not a matter of switching. Sometimes verbosity, and the things it negatively impacts, are worth switching. That's what.

Re:Code faster with Intellij IDEA live templates by voidr on Tuesday January 21, 2014 @05:47AM (#7094483)
The only way stacks evolve is if we start a dialog on how unnecessarily verbose they are, you don't just write that verbose code/configuration, you will have to read it some time in the future, your IDE might not be able to help you out then.
Re:Code faster with Intellij IDEA live templates by reeses on Saturday January 18, 2014 @02:34PM (#7081922)
In general, macros, templates, and patterns are an "almost" discovery that a user needs a language (task, whatever) to have another level of abstraction or factorization for the activity at hand.

For example, the visitor pattern is easily eliminated by dispatching on multiple arguments or with a monad.

The template provides that common, low-level, way of communicating to other developers in that the resulting code is consistently formatted and is native java/c/etc.. It's a pain in the ass to deal with constructs such as conventional iterative loops, exception handling boilerplate, braces/whitespace/etc., or massively redundant structures such as XML, as a regular programmer.

My favorite example of a level of 'retardation' in a language is pattern matching.

I can either write a painful if/then/else/else/else/else/else/default/end tree or I can write something like the following.

f(0) → 0. f(1) → 1. f(<binary:01001001010101011101010><x as binary>) → x as number. f(x > 10) → 1.

Of course, this can be expressed in a number of ways. Table? Spreadsheet? Domain mapping with pretty lines?

I think we're losing information on a lot of the footpaths we should be paving by not having feedback into the use of various macros, templates, and patterns in the world.

Re:Code faster with Intellij IDEA live templates by andybak on Saturday January 18, 2014 @02:37PM (#7081939)
Re:Code faster with Intellij IDEA live templates by reeses on Sunday January 19, 2014 @11:35PM (#7087594)
Hah, I was caught out repeating myself. :) I remember kvetching on that c2 page early this century.
Re:Code faster with Intellij IDEA live templates by mortyseinfeld on Saturday January 18, 2014 @01:34PM (#7081718)
It's useful for any language/framework, whether it's verbose or not.

The benefits of functional languages tend to not be as great as they could be because the tooling sucks (or kind of sucks). Look at Scala. The IDEs sucked for years. That's changed recently, but it was a big problem for adoption. F# is similar. Although support is baked into Visual Studio these days, the IDE support is spartan to say the least compared to C# with resharper.

There seems to be a class of developers that have a hard time understanding the enormous productivity boosts that good tooling provides.

Re:Code faster with Intellij IDEA live templates by mateuszf on Saturday January 18, 2014 @03:53PM (#7082200)
I've heard that Clojure support is good in most popular IDEs/editors.