summaryrefslogtreecommitdiff
path: root/chapter05/src
diff options
context:
space:
mode:
authordibyendumajumdar <mobile@majumdar.org.uk>2023-10-28 12:13:35 +0100
committerDibyendu Majumdar <dibyendumajumdar@users.noreply.github.com>2023-11-01 18:56:50 +0000
commitd438edc542ae524c69cd0a5259c76313cf3abc76 (patch)
tree580234f9759ea4d22907b00e1310fdd9d4a5de39 /chapter05/src
parent45f134cfdb467c2f8fe4b9c352902775ecc31547 (diff)
downloadSimple-d438edc542ae524c69cd0a5259c76313cf3abc76.tar.gz
Simple-d438edc542ae524c69cd0a5259c76313cf3abc76.zip
Add writeup of if statement parsing
Diffstat (limited to 'chapter05/src')
-rw-r--r--chapter05/src/main/java/com/seaofnodes/simple/Parser.java1
1 files changed, 1 insertions, 0 deletions
diff --git a/chapter05/src/main/java/com/seaofnodes/simple/Parser.java b/chapter05/src/main/java/com/seaofnodes/simple/Parser.java
index 2953ec26..b141d7ac 100644
--- a/chapter05/src/main/java/com/seaofnodes/simple/Parser.java
+++ b/chapter05/src/main/java/com/seaofnodes/simple/Parser.java
@@ -146,6 +146,7 @@ public class Parser {
// Create region node and merge scopes
// If a var is in both scopes and has different binding then we need to create PhiNode for it
// After merge _scope remains, and ifScope is discarded
+ System.out.println(new GraphVisualizer().generateDotOutput(this));
RegionNode region = mergeScopes(ifT, ifScope, ifF, _scope);
updateCtrlToken(region); // Now region becomes the ctrl token
ifScope.clear(); // Clean up ifScope