Issue #179 Foreach broken because of precontinues

This commit is contained in:
Jindra Petk
2013-07-05 21:22:29 +02:00
parent ecbf47921f
commit 8b7a4e36fc

View File

@@ -992,7 +992,18 @@ public class Graph {
for (GraphPart t : part.throwParts) {
if (!visited.contains(t)) {
markLevels(t, loops, stopPart, level, visited);
List<GraphPart> stopPart2 = new ArrayList<>();
List<GraphPart> cmn = new ArrayList<>();
cmn.add(part);
cmn.add(t);
GraphPart next = getCommonPart(cmn, loops);
if (next != null) {
stopPart2.add(next);
} else {
stopPart2 = stopPart;
}
markLevels(t, loops, stopPart2, level, visited);
}
}