Details
-
Type:
Bug
-
Status:
Resolved
-
Priority:
Critical
-
Resolution: Fixed
-
Affects Version/s: None
-
Fix Version/s: None
-
Component/s: None
-
Labels:None
-
Environment:WinXP
-
Testcase included:yes
-
Number of attachments :
Description
I recently tried to update to Janino 2.4.5, but ran into a new regression. As a result, I have to keep using
a very old 2.3.18 release. I have included a small test case that shows the error:
$ janinoc Loop22.java
File Loop22.java, Line 12, Column 21: "continue" statement is not enclosed by a continuable statement
org.codehaus.janino.CompileException: 1 errors while compiling unit "Loop22.java
"
Save as:
janino\src\org\codehaus\janino\util\iterator\ScopeIterator.java
and:
janino\src\org\codehaus\janino\scope_iterator.patch
Then apply scope_iterator.patch to UnitCompiler.java.
This fixes up the ugly scope iteration issues for the break
and continue statements in try blocks.