Details
-
Bug
-
Status: Closed
-
Critical
-
Resolution: Fixed
-
None
-
None
-
None
Description
class Foo {
doSomething() {
data = ["name": "James", "location": "London"]
for (e in data) {
println("property ${e.key} is ${e.value}")
}
}
closureExample(collection) {
collection.each { println("value ${it}") }
}
static void main(args)
{ values = [1, 2, 3, "abc"] closureExample(values) }}
does not work since closureExample is not a static method