summaryrefslogtreecommitdiffstats
path: root/Python
diff options
context:
space:
mode:
Diffstat (limited to 'Python')
-rw-r--r--Python/compile.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/Python/compile.c b/Python/compile.c
index 1cf20d3..786ef4e 100644
--- a/Python/compile.c
+++ b/Python/compile.c
@@ -7534,6 +7534,11 @@ normalize_jumps(struct assembler *a)
last->i_opcode = JUMP_FORWARD;
}
}
+ if (last->i_opcode == JUMP_FORWARD) {
+ if (last->i_target->b_visited == 1) {
+ last->i_opcode = JUMP_ABSOLUTE;
+ }
+ }
}
}