Fixed: label copies should be added to all labels
This commit is contained in:
@@ -460,7 +460,7 @@ public class PseudocodeImpl implements Pseudocode {
|
||||
Integer finishIndex = ((PseudocodeLabel) finishLabel).getTargetInstructionIndex();
|
||||
assert finishIndex != null;
|
||||
|
||||
Map<Label, Label> originalToCopy = Maps.newHashMap();
|
||||
Map<Label, Label> originalToCopy = Maps.newLinkedHashMap();
|
||||
Multimap<Instruction, Label> originalLabelsForInstruction = HashMultimap.create();
|
||||
for (PseudocodeLabel label : labels) {
|
||||
Integer index = label.getTargetInstructionIndex();
|
||||
@@ -472,6 +472,9 @@ public class PseudocodeImpl implements Pseudocode {
|
||||
originalLabelsForInstruction.put(getJumpTarget(label), label);
|
||||
}
|
||||
}
|
||||
for (Label label : originalToCopy.values()) {
|
||||
labels.add((PseudocodeLabel) label);
|
||||
}
|
||||
for (int index = startIndex; index < finishIndex; index++) {
|
||||
Instruction originalInstruction = mutableInstructionList.get(index);
|
||||
repeatLabelsBindingForInstruction(originalInstruction, originalToCopy, originalLabelsForInstruction);
|
||||
|
||||
Reference in New Issue
Block a user