diff options
Diffstat (limited to 'src/main/com/jantuomi/tunkki/exception/TunkkiError.java')
| -rw-r--r-- | src/main/com/jantuomi/tunkki/exception/TunkkiError.java | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/main/com/jantuomi/tunkki/exception/TunkkiError.java b/src/main/com/jantuomi/tunkki/exception/TunkkiError.java index affc353..b5a36a7 100644 --- a/src/main/com/jantuomi/tunkki/exception/TunkkiError.java +++ b/src/main/com/jantuomi/tunkki/exception/TunkkiError.java @@ -20,7 +20,9 @@ public class TunkkiError extends Exception { UndeclaredSymbolError, IncludeError, GeneralError, - CastError, NadaError + CastError, + DivisionByZeroError, + NadaError } private static Map<ExceptionType, String> errorTexts = new HashMap<>(); @@ -36,6 +38,7 @@ public class TunkkiError extends Exception { errorTexts.put(ExceptionType.GeneralError, "%s"); errorTexts.put(ExceptionType.NadaError, "Can't do operation with a nada value."); errorTexts.put(ExceptionType.CastError, "Illegal cast to type %s from value %s."); + errorTexts.put(ExceptionType.DivisionByZeroError, "Division by zero."); } private ExceptionType exceptionType; |
