AS3 loop break fixed - tests now pass

This commit is contained in:
Jindra Petřík
2015-07-03 17:24:32 +02:00
parent bc59d42957
commit ab5e79632b

View File

@@ -1700,7 +1700,10 @@ public class Graph {
} else if (loopItem.commands.size() == 2 && (loopItem.commands.get(1) instanceof BreakItem)) {
BreakItem bi = (BreakItem) loopItem.commands.get(1);
if (bi.loopId == currentLoop.id) {
bodyBranch = ifi.onTrue;
if (ifi.onTrue.isEmpty()) {
inverted = true;
}
bodyBranch = inverted ? ifi.onFalse : ifi.onTrue;
breakpos2 = true;
}
}