diff options
-rw-r--r-- | checker/check.mllib | 1 | ||||
-rw-r--r-- | dev/printers.mllib | 2 | ||||
-rw-r--r-- | grammar/grammar.mllib | 1 | ||||
-rw-r--r-- | lib/clib.mllib | 1 | ||||
-rw-r--r-- | lib/int.ml | 15 | ||||
-rw-r--r-- | lib/int.mli | 17 |
6 files changed, 37 insertions, 0 deletions
diff --git a/checker/check.mllib b/checker/check.mllib index ea3cb6a8a..bd3c5e00f 100644 --- a/checker/check.mllib +++ b/checker/check.mllib @@ -1,4 +1,5 @@ Coq_config +Int Pp_control Flags Pp diff --git a/dev/printers.mllib b/dev/printers.mllib index 6f34dbb09..f0221a9c5 100644 --- a/dev/printers.mllib +++ b/dev/printers.mllib @@ -1,5 +1,6 @@ Coq_config +Int Pp_control Loc Compat @@ -107,6 +108,7 @@ Pretyping Declaremods Tok +Int Lexer Ppextend Pputils diff --git a/grammar/grammar.mllib b/grammar/grammar.mllib index 7d91550df..ee1bb3258 100644 --- a/grammar/grammar.mllib +++ b/grammar/grammar.mllib @@ -1,5 +1,6 @@ Coq_config +Int Pp_control Flags Pp diff --git a/lib/clib.mllib b/lib/clib.mllib index ca0e97bb0..f5fd72113 100644 --- a/lib/clib.mllib +++ b/lib/clib.mllib @@ -1,3 +1,4 @@ +Int Pp_control Pp Coq_config diff --git a/lib/int.ml b/lib/int.ml new file mode 100644 index 000000000..19cdfac0a --- /dev/null +++ b/lib/int.ml @@ -0,0 +1,15 @@ +(************************************************************************) +(* v * The Coq Proof Assistant / The Coq Development Team *) +(* <O___,, * INRIA - CNRS - LIX - LRI - PPS - Copyright 1999-2012 *) +(* \VV/ **************************************************************) +(* // * This file is distributed under the terms of the *) +(* * GNU Lesser General Public License Version 2.1 *) +(************************************************************************) + +type t = int + +external equal : int -> int -> bool = "%eq" + +external compare : int -> int -> int = "caml_int_compare" + +let hash i = i land max_int diff --git a/lib/int.mli b/lib/int.mli new file mode 100644 index 000000000..ae1a32dc8 --- /dev/null +++ b/lib/int.mli @@ -0,0 +1,17 @@ +(************************************************************************) +(* v * The Coq Proof Assistant / The Coq Development Team *) +(* <O___,, * INRIA - CNRS - LIX - LRI - PPS - Copyright 1999-2012 *) +(* \VV/ **************************************************************) +(* // * This file is distributed under the terms of the *) +(* * GNU Lesser General Public License Version 2.1 *) +(************************************************************************) + +(** A native integer module with usual utility functions. *) + +type t = int + +external equal : t -> t -> bool = "%eq" + +external compare : t -> t -> int = "caml_int_compare" + +val hash : t -> int |