Details
-
Bug
-
Status: Closed
-
Critical
-
Resolution: Duplicate
-
2.4.2
-
None
Description
After switching to Groovy 2.4.2 I get the following error when trying to compile the attached file (via Gradle):
BUG! exception in phase 'class generation' in source unit '/mirror/ImpetusGames/Code/ImpetusGDX/src/ecs/lib/comp/TiledMapComponent.groovy' CompileStack#removeVar: tried to remove a temporary variable with index 2 in wrong order. Current temporary variables=[switch(index=4,type=java.lang.Object,holder=false), iterator(index=2,type=java.util.Iterator <E extends java.lang.Object -> java.lang.Object>,holder=false)]
This code worked in the previous Groovy versions up to 2.4.1 without any issue. Since I cannot find the root cause of this problem, I have attached the full source code file here.