Being a Java programmer, I don\'t really have a Groovy background, but I use Groovy a lot lately to extend Maven (using GMaven). So far, I could use all the Java code I need
Others have already given examples of Java syntax that is illegal in Groovy (e.g. literal arrays). It is also worth remembering that some syntax which is legal in both, does not mean the same thing in both languages. For example in Java:
foo == bar
tests for identity, i.e. do foo
and bar
both refer to the same object? In Groovy, this tests for object equality, i.e. it returns the result of foo.equals(bar)