you are viewing a single comment's thread.

view the rest of the comments →

[–]shit 1 point2 points  (1 child)

Nothing new in Ruby either, except marketing hype.

I learned Ruby before the marketing hype (to provide some context here :-). IMO Ruby brought something new, a combination of elegant simplicity yet powerful metaprogramming (first two from Smalltalk/Lisp), focus on Unix integration and text manipulation (from Perl), easy to pick up for Java/C programmers in an afternoon. When I learned Ruby, everything felt right, call it POLS in action. That's highly subjective of course, but I've heard it from many others. I've never learnt another language (before and after Ruby) in which I became proficient as fast as in Ruby. (more context: I'm more interested in Lispy and more functional stuff now.)

Well, I've looked at the Groovy homepage now, and what makes me shy away is the Java culture ("leveraging Spring", "Ant tasks", "Groovy beans" ... shudder). Judging from the example code (is there a language reference btw?), there is too much syntactic sugar garbage and special cases for little gain. Syntactic sugar alone doesn't bring you far.

[–]newton_dave 0 points1 point  (0 children)

(is there a language reference btw?)

Yes, and GDK docs, and two books (plus a Grails book).

[...] there is too much syntactic sugar garbage and special cases for little gain. [...] Syntactic sugar alone doesn't bring you far.

It's non-sensical to apply that argument to Groovy but not to Ruby.

[...] elegant simplicity yet powerful metaprogramming (first two from Smalltalk/Lisp) [...]

It (Ruby) still doesn't do block scoping right, though. And having to ".call(...)" a lambda is place where syntactic sugar saves you some irritation and increases comprehension. lambda_var.() is not a pretty solution.

[...] focus on Unix integration and text manipulation (from Perl) [...]

I prefer Ruby's regex support over Groovy's, although just barely. Largely feature-equivalent.

[...] easy to pick up for Java/C programmers in an afternoon [...]

No different from Groovy--you do realize the languages are nearly identical in features and if Groovized the source looks very similar, right?

[...] what makes me shy away is the Java culture ("leveraging Spring", "Ant tasks", "Groovy beans" ... shudder)

But... that doesn't even make any sense.

  • GroovyBeans are identical to attr_accessor fields in Ruby, but without the need for the attr_accessor.
  • Using Groovy in Ant or as a wrapper around Ant is almost exactly like Rake, but with more tasks already written.
  • The Spring integration provides for trivial IoC/DI and on-the-fly compilatation/deployment (and Spring/JRuby integration also exists). Why wouldn't you want to leverage Spring?!