aboutsummaryrefslogtreecommitdiffstats
path: root/src/com/craftinginterpreters/lox/RuntimeError.java
diff options
context:
space:
mode:
authorGravatar Tom Willemse2020-11-11 21:33:02 -0800
committerGravatar Tom Willemse2020-11-11 21:33:02 -0800
commitee63307aee839c7ce5e7bf032402a3b05809c51e (patch)
treefeccbfc402460125b3182f504eabb153dc24e762 /src/com/craftinginterpreters/lox/RuntimeError.java
parenta78fe97f60c2ad39d3d6335c1d058bd8ee4921bb (diff)
downloadcrafting-interpreters-ee63307aee839c7ce5e7bf032402a3b05809c51e.tar.gz
crafting-interpreters-ee63307aee839c7ce5e7bf032402a3b05809c51e.zip
Add the interpreter
Diffstat (limited to 'src/com/craftinginterpreters/lox/RuntimeError.java')
-rw-r--r--src/com/craftinginterpreters/lox/RuntimeError.java10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/com/craftinginterpreters/lox/RuntimeError.java b/src/com/craftinginterpreters/lox/RuntimeError.java
new file mode 100644
index 0000000..017865b
--- /dev/null
+++ b/src/com/craftinginterpreters/lox/RuntimeError.java
@@ -0,0 +1,10 @@
+package com.craftinginterpreters.lox;
+
+class RuntimeError extends RuntimeException {
+ final Token token;
+
+ RuntimeError(Token token, String message) {
+ super(message);
+ this.token = token;
+ }
+}