aboutsummaryrefslogtreecommitdiffstats
path: root/main/exception/ExceptionManager.java
diff options
context:
space:
mode:
Diffstat (limited to 'main/exception/ExceptionManager.java')
-rw-r--r--main/exception/ExceptionManager.java10
1 files changed, 3 insertions, 7 deletions
diff --git a/main/exception/ExceptionManager.java b/main/exception/ExceptionManager.java
index 0ceb25b..dbb59d3 100644
--- a/main/exception/ExceptionManager.java
+++ b/main/exception/ExceptionManager.java
@@ -16,13 +16,9 @@ public class ExceptionManager {
return instance;
}
- public static void raise(InterpreterException.Exception ex, int line, List<String> args) {
- InterpreterException e = new InterpreterException(ex);
- String output = e.what();
- for (String arg : args) {
- output = String.format(output, arg);
- }
- System.err.println(String.format("[%s] line: %d %s", ex.toString(), line, output));
+ public static void raise(InterpreterException.ExceptionType ex, int line, List<String> args) throws InterpreterException {
+ InterpreterException e = new InterpreterException(ex, line, args);
+ throw e;
}