2 ||M|| This file is part of HELM, an Hypertextual, Electronic
3 ||A|| Library of Mathematics, developed at the Computer Science
4 ||T|| Department, University of Bologna, Italy.
6 ||T|| HELM is free software; you can redistribute it and/or
7 ||A|| modify it under the terms of the GNU General Public License
8 \ / version 2 or (at your option) any later version.
9 \ / This software is distributed as is, NO WARRANTY.
10 V_______________________________________________________________ *)
14 exception CircularDependency of string Lazy.t;;
15 exception ObjectNotFound of string Lazy.t;;
16 exception BadDependency of string Lazy.t * exn;;
17 exception AlreadyDefined of string Lazy.t;;
19 val set_get_obj: (NUri.uri -> NCic.obj) -> unit
21 val get_checked_obj: NUri.uri -> NCic.obj
23 val check_and_add_obj: NCic.obj -> unit
25 val get_relevance: NReference.reference -> bool list
28 NReference.reference ->
29 NCic.relevance * string * NCic.term * NCic.term * NCic.c_attr * int
31 (* the last integer is the index of the inductive type in the reference *)
32 val get_checked_indtys:
33 NReference.reference ->
34 bool * int * NCic.inductiveType list * NCic.i_attr * int
36 val get_checked_fixes_or_cofixes:
37 NReference.reference ->
38 NCic.inductiveFun list * NCic.f_attr * int
40 (* invalidate the object and all those that entered the environment after it *)
42 [ `Obj of NUri.uri * NCic.obj
43 | `Constr of NCic.universe * NCic.universe ] -> unit
45 val invalidate: unit -> unit
47 val set_typecheck_obj: (NCic.obj -> unit) -> unit
49 (* =========== universes ============= *)
52 val ppsort : Format.formatter -> NCic.sort -> unit
53 val pp_constraints: unit -> string
54 val get_universes: unit -> NCic.universe list
56 (* use to type products *)
57 val max: NCic.universe -> NCic.universe -> NCic.universe
59 (* raise BadConstraints if the second arg. is an inferred universe or
60 * if the added constraint gives circularity *)
61 exception BadConstraint of string Lazy.t;;
62 val add_lt_constraint: NCic.universe -> NCic.universe -> unit
63 val universe_eq: NCic.universe -> NCic.universe -> bool
64 val universe_leq: NCic.universe -> NCic.universe -> bool
65 val universe_lt: NCic.universe -> NCic.universe -> bool
67 (* checks if s1 <= s2 *)
68 val are_sorts_convertible: test_eq_only:bool -> NCic.sort -> NCic.sort -> bool
71 val allowed_sort_elimination: NCic.sort -> NCic.sort -> [ `Yes | `UnitOnly ]
73 (* algebraic successor function *)
74 exception UntypableSort of string Lazy.t
75 exception AssertFailure of string Lazy.t
76 val typeof_sort: NCic.sort -> NCic.sort
78 (* looks for a declared universe that is the least one above the input *)
79 val sup : NCic.universe -> NCic.universe option
80 val inf : strict:bool -> NCic.universe -> NCic.universe option
81 val family_of : NCic.universe -> [ `CProp | `Type ]
83 (* =========== /universes ============= *)