From 185a8ea39b1dbd795aa54b7b9c82e393a9185765 Mon Sep 17 00:00:00 2001 From: Alex AUVOLAT Date: Fri, 6 Dec 2013 19:53:07 +0100 Subject: Corrected many bugs, improved error reporting. --- src/main.ml | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'src/main.ml') diff --git a/src/main.ml b/src/main.ml index 1a7d5b1..ca1134a 100644 --- a/src/main.ml +++ b/src/main.ml @@ -2,6 +2,7 @@ open Format open Lexing let parse_only = ref false +let type_only = ref false let dump = ref false let dumpt = ref false @@ -26,6 +27,7 @@ let localisation2 (pos1,pos2) = let options = [ "--parse-only", Arg.Set parse_only, "Stops after parsing of the input file."; + "--type-only", Arg.Set type_only, "Stops after typechecking of the input file."; "--dump", Arg.Set dump, "Dump the AST after parsing."; "--dumpt", Arg.Set dumpt, "Dump the AST after typing." ] @@ -53,6 +55,10 @@ let () = if not !parse_only then begin let t = Typing.prog p in if !dumpt then Pretty_typing.print_prog t; + + if not !type_only then begin + () + end end with | Lexer.Lexing_error s -> -- cgit v1.2.3