diff options
Diffstat (limited to 'src/com/craftinginterpreters/lox/Lox.java')
-rw-r--r-- | src/com/craftinginterpreters/lox/Lox.java | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/com/craftinginterpreters/lox/Lox.java b/src/com/craftinginterpreters/lox/Lox.java index bca117e..6115f8f 100644 --- a/src/com/craftinginterpreters/lox/Lox.java +++ b/src/com/craftinginterpreters/lox/Lox.java @@ -59,6 +59,13 @@ public class Lox { if (hadError) return; + Resolver resolver = new Resolver(interpreter); + resolver.resolve(statements); + + // Stop if there was a resolution error + if (hadError) + return; + interpreter.interpret(statements); } |