1 (* Copyright (C) 2000, HELM Team.
3 * This file is part of HELM, an Hypertextual, Electronic
4 * Library of Mathematics, developed at the Computer Science
5 * Department, University of Bologna, Italy.
7 * HELM is free software; you can redistribute it and/or
8 * modify it under the terms of the GNU General Public License
9 * as published by the Free Software Foundation; either version 2
10 * of the License, or (at your option) any later version.
12 * HELM is distributed in the hope that it will be useful,
13 * but WITHOUT ANY WARRANTY; without even the implied warranty of
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 * GNU General Public License for more details.
17 * You should have received a copy of the GNU General Public License
18 * along with HELM; if not, write to the Free Software
19 * Foundation, Inc., 59 Temple Place - Suite 330, Boston,
22 * For details, see the HELM World-Wide-Web page,
23 * http://cs.unibo.it/helm/.
27 type joint_recursion_kind =
28 [ `Recursive of int list (* decreasing arguments *)
30 | `Inductive of int (* paramsno *)
31 | `CoInductive of int (* paramsno *)
35 type var_or_const = Var | Const;;
37 type 'term declaration =
38 { dec_name : string option;
46 type 'term definition =
47 { def_name : string option;
54 type 'term inductive =
56 inductive_name : string;
57 inductive_kind : bool;
58 inductive_type : 'term;
59 inductive_constructors : 'term declaration list
63 type 'term decl_context_element =
64 [ `Declaration of 'term declaration
65 | `Hypothesis of 'term declaration
69 type ('term,'proof) def_context_element =
71 | `Definition of 'term definition
75 type ('term,'proof) in_joint_context_element =
76 [ `Inductive of 'term inductive
77 | 'term decl_context_element
78 | ('term,'proof) def_context_element
82 type ('term,'proof) joint =
84 joint_kind : joint_recursion_kind ;
85 joint_defs : ('term,'proof) in_joint_context_element list
89 type ('term,'proof) joint_context_element =
90 [ `Joint of ('term,'proof) joint ]
94 { proof_name : string option;
96 proof_context : 'term in_proof_context_element list ;
97 proof_apply_context: 'term proof list;
98 proof_conclude : 'term conclude_item
101 and 'term in_proof_context_element =
102 [ 'term decl_context_element
103 | ('term,'term proof) def_context_element
104 | ('term,'term proof) joint_context_element
107 and 'term conclude_item =
109 conclude_aref : string;
110 conclude_method : string;
111 conclude_args : ('term arg) list ;
112 conclude_conclusion : 'term option
119 | Term of bool * 'term (* inferrable, term *)
120 | ArgProof of 'term proof
121 | ArgMethod of string (* ???? *)
125 premise_xref : string ;
126 premise_binder : string option;
127 premise_n : int option;
137 type 'term conjecture = id * int * 'term context * 'term
139 and 'term context = 'term hypothesis list
141 and 'term hypothesis =
142 ['term decl_context_element | ('term,'term proof) def_context_element ] option
145 type 'term in_object_context_element =
146 [ `Decl of var_or_const * 'term decl_context_element
147 | `Def of var_or_const * 'term * ('term,'term proof) def_context_element
148 | ('term,'term proof) joint_context_element
154 UriManager.uri list * (* params *)
155 'term conjecture list option * (* optional metasenv *)
156 'term in_object_context_element (* actual object *)