Details
-
Bug
-
Status: Closed
-
Minor
-
Resolution: Fixed
-
3.0.19
-
None
Description
Hi there, this code compiled up until groovy 3.0.18, in 3.0.19 stopped compiling:
@groovy.transform.CompileStatic class Prueba { public static void main(String[] args) { [ [1], ['a'], ].transpose().each { int a, String b -> println(a) println(b) } } }
$ groovy Prueba.groovy org.codehaus.groovy.control.MultipleCompilationErrorsException: startup failed: /home/becho/Prueba.groovy: 9: Incorrect number of parameters. Expected 1 but found 2 @ line 9, column 22. ].transpose().each { int a, String b -> ^1 error
Is this an expected behavior? Or something got broken along the way?
Attachments
Issue Links
- is related to
-
GROOVY-11089 STC: closure param type inference for array and list
- Closed
-
GROOVY-11092 STC: support coerced closure argument destructuring (for list and tuple)
- Closed