Details
-
Bug
-
Status: Closed
-
Major
-
Resolution: Fixed
-
2.0.5
-
None
Description
The following:
@groovy.transform.CompileStatic Integer[] m() { Integer[] arr = [ null, null ] } println m()
Throws:
[Static type checking] - Cannot assign value of type java.lang.Object into array of type [Ljava.lang.Integer;
To get it to work, either remove CompileStatic, or change the function to:
@groovy.transform.CompileStatic Integer[] m() { Integer[] arr = [ null, null ] as Integer[] } println m()