The problem manifests when a long value is effectively being changed to an 'int' and results in an exception during compilation.
Using groovy 1.8.5, the generated stub (during joint compilation using the 'Groovyc' ant taskdef) looks like (sans imports):
The problem is that this yields a compilation exception 'integer number too large'.
If you exclude the 'public' keyword on the member definition and re-compile, the stub instead looks like:
This can then compile successfully.