Is anyone doing much groovy with groovyConsole? I've noticed that if I make a for look with commas groovy won't accept it in the GUI console:
Code:
int b = 4
for (int a = 0; a < b; a++,b--) {
//b--
println "a: " + a + " b: " + b
}
1 compilation error:
expecting ")" found "," ....
then if I remove the ", b--" and comment back in the "// b-- " it works fine
Code:
a: 0 b: 3
a: 1 b: 2
But commas in the for statement are valid Java. This is with Groovy version 1.8.6 on Oracle JDK 1.6.0_31 64bit on Fedora 16. Is this a limitation in the groovyConsole?