aboutsummaryrefslogtreecommitdiff
path: root/lib/errors.mli
diff options
context:
space:
mode:
authorpboutill2012-03-02 22:30:29 +0000
committerpboutill2012-03-02 22:30:29 +0000
commit401f17afa2e9cc3f2d734aef0d71a2c363838ebd (patch)
tree7a3e0ce211585d4c09a182aad1358dfae0fb38ef /lib/errors.mli
parent15cb1aace0460e614e8af1269d874dfc296687b0 (diff)
Noise for nothing
Util only depends on Ocaml stdlib and Utf8 tables. Generic pretty printing and loc functions are in Pp. Generic errors are in Errors. + Training white-spaces, useless open, prlist copies random erasure. Too many "open Errors" on the contrary. git-svn-id: svn+ssh://scm.gforge.inria.fr/svn/coq/trunk@15020 85f007b7-540e-0410-9357-904b9bb8a0f7
Diffstat (limited to 'lib/errors.mli')
-rw-r--r--lib/errors.mli36
1 files changed, 36 insertions, 0 deletions
diff --git a/lib/errors.mli b/lib/errors.mli
index eb7fde8e77..a863c5e30e 100644
--- a/lib/errors.mli
+++ b/lib/errors.mli
@@ -6,9 +6,45 @@
(* * GNU Lesser General Public License Version 2.1 *)
(***********************************************************************)
+open Pp
+
(** This modules implements basic manipulations of errors for use
throughout Coq's code. *)
+(** {6 Generic errors.}
+
+ [Anomaly] is used for system errors and [UserError] for the
+ user's ones. *)
+
+exception Anomaly of string * std_ppcmds
+val anomaly : string -> 'a
+val anomalylabstrm : string -> std_ppcmds -> 'a
+val anomaly_loc : loc * string * std_ppcmds -> 'a
+
+exception UserError of string * std_ppcmds
+val error : string -> 'a
+val errorlabstrm : string -> std_ppcmds -> 'a
+val user_err_loc : loc * string * std_ppcmds -> 'a
+
+exception AlreadyDeclared of std_ppcmds
+val alreadydeclared : std_ppcmds -> 'a
+
+val invalid_arg_loc : loc * string -> 'a
+
+(** [todo] is for running of an incomplete code its implementation is
+ "do nothing" (or print a message), but this function should not be
+ used in a released code *)
+
+val todo : string -> unit
+
+exception Timeout
+
+(** Like [Exc_located], but specifies the outermost file read, the
+ input buffer associated to the location of the error (or the module name
+ if boolean is true), and the error itself. *)
+
+exception Error_in_file of string * (bool * string * loc) * exn
+
(** [register_handler h] registers [h] as a handler.
When an expression is printed with [print e], it
goes through all registered handles (the most