diff options
| author | Alasdair Armstrong | 2019-02-12 18:18:05 +0000 |
|---|---|---|
| committer | Alasdair Armstrong | 2019-02-12 18:18:05 +0000 |
| commit | 24fc989891ad266eae642815646294279e2485ca (patch) | |
| tree | d533fc26b5980d1144ee4d7849d3dd0f2a1b0e95 /src/reporting.mli | |
| parent | b847a472a1f853d783d1af5f8eb033b97f33be5b (diff) | |
| parent | 974494b1dda38c1ee5c1502cc6e448e67a7374ac (diff) | |
Merge remote-tracking branch 'origin/asl_flow2' into sail2
Diffstat (limited to 'src/reporting.mli')
| -rw-r--r-- | src/reporting.mli | 14 |
1 files changed, 4 insertions, 10 deletions
diff --git a/src/reporting.mli b/src/reporting.mli index 63ed3eee..2d886111 100644 --- a/src/reporting.mli +++ b/src/reporting.mli @@ -69,13 +69,13 @@ val loc_to_string : ?code:bool -> Parse_ast.l -> string std-err. It starts with printing location information stored in [l] It then prints "head: mes". If [fatal] is set, the program exists with error-code 1 afterwards. *) -val print_err : bool -> bool -> Parse_ast.l -> string -> string -> unit +val print_err : Parse_ast.l -> string -> string -> unit (** {2 Errors } *) (** Errors stop execution and print a message; they typically have a location and message. *) -type error = +type error = (** General errors, used for multi purpose. If you are unsure, use this one. *) | Err_general of Parse_ast.l * string @@ -90,8 +90,7 @@ type error = | Err_syntax_locn of Parse_ast.l * string | Err_lex of Lexing.position * string | Err_type of Parse_ast.l * string - | Err_type_dual of Parse_ast.l * Parse_ast.l * string - + exception Fatal_error of error (** [err_todo l m] is an abreviatiation for [Fatal_error (Err_todo (l, m))] *) @@ -106,11 +105,6 @@ val err_unreachable : Parse_ast.l -> (string * int * int * int) -> string -> exn (** [err_typ l m] is an abreviatiation for [Fatal_error (Err_type (l, m))] *) val err_typ : Parse_ast.l -> string -> exn -(** [err_typ_dual l1 l2 m] is an abreviatiation for [Fatal_error (Err_type_dual (l1, l2, m))] *) -val err_typ_dual : Parse_ast.l -> Parse_ast.l -> string -> exn - -(** Report error should only be used by main to print the error in the end. Everywhere else, - raising a [Fatal_error] exception is recommended. *) -val report_error : error -> 'a +val unreachable : Parse_ast.l -> (string * int * int * int) -> string -> 'a val print_error : error -> unit |
