summaryrefslogtreecommitdiff
path: root/src/main.ml
diff options
context:
space:
mode:
Diffstat (limited to 'src/main.ml')
-rw-r--r--src/main.ml9
1 files changed, 6 insertions, 3 deletions
diff --git a/src/main.ml b/src/main.ml
index 35bd6e0..1a7d5b1 100644
--- a/src/main.ml
+++ b/src/main.ml
@@ -63,11 +63,14 @@ let () =
localisation (Lexing.lexeme_start_p buf);
eprintf "Parsing error.@.";
exit 1
- | Typing.Error (loc, msg) ->
+ | Typing.Error(msg) ->
+ eprintf "Typing error (unknown location): %s@." msg;
+ exit 2
+ | Typing.LocError (loc, msg) ->
localisation2 loc;
eprintf "%s@." msg;
- exit 1
+ exit 2
| _ ->
eprintf "Unexpected error...@.";
- exit 2
+ exit 3