diff --git a/examples/test/to_ssa/if-const.out b/examples/test/to_ssa/if-const.out index 84b19da84..d3578a70b 100644 --- a/examples/test/to_ssa/if-const.out +++ b/examples/test/to_ssa/if-const.out @@ -9,7 +9,7 @@ b.0: int = const 1; jmp .zexit; .zexit: - b.1: int = phi b.0 b.0 .false .true; + b.1: int = phi b.0 __undefined .false .true; a.1: int = phi __undefined a.0 .false .true; print a.1; ret; diff --git a/examples/test/to_ssa/if-ssa.out b/examples/test/to_ssa/if-ssa.out index c9d635ace..e8fee00e7 100644 --- a/examples/test/to_ssa/if-ssa.out +++ b/examples/test/to_ssa/if-ssa.out @@ -10,7 +10,7 @@ jmp .zexit; .zexit: a.3.1: int = phi __undefined a.3.0 .left .right; - a.2.1: int = phi a.2.0 a.2.0 .left .right; + a.2.1: int = phi a.2.0 __undefined .left .right; a.4.0: int = phi a.2.1 a.3.1 .left .right; print a.4.0; ret; diff --git a/examples/to_ssa.py b/examples/to_ssa.py index b716ac217..62de7b3be 100644 --- a/examples/to_ssa.py +++ b/examples/to_ssa.py @@ -83,6 +83,7 @@ def _rename(block): _rename(b) # Restore stacks. + stack.clear() stack.update(old_stack) entry = list(blocks.keys())[0]