Given following groovy function:
def foo(List params, Closure c) {...}
The method call would be:
foo([\'a\', \'b
Seeing that it's impossible to achieve exactly what you want (it's written in Groovy documentation that your specific case is a problem, unfortunately they are migrating the docs so I can't directly link right now), what about something along these lines:
def foo(String... params) {
println params
return { Closure c ->
c.call()
}
}
foo('a', 'b') ({ println 'woot' })
Now you need to put the closure in parantheses, but you don't need to use an array anymore..