7 resolution), oracles. |
7 resolution), oracles. |
8 *) |
8 *) |
9 |
9 |
10 signature BASIC_THM = |
10 signature BASIC_THM = |
11 sig |
11 sig |
|
12 type ctyp |
|
13 type cterm |
|
14 exception CTERM of string * cterm list |
|
15 type thm |
|
16 type conv = cterm -> thm |
|
17 exception THM of string * int * thm list |
|
18 end; |
|
19 |
|
20 signature THM = |
|
21 sig |
|
22 include BASIC_THM |
|
23 |
12 (*certified types*) |
24 (*certified types*) |
13 type ctyp |
|
14 val rep_ctyp: ctyp -> {thy: theory, T: typ, maxidx: int, sorts: sort Ord_List.T} |
25 val rep_ctyp: ctyp -> {thy: theory, T: typ, maxidx: int, sorts: sort Ord_List.T} |
15 val theory_of_ctyp: ctyp -> theory |
26 val theory_of_ctyp: ctyp -> theory |
16 val typ_of: ctyp -> typ |
27 val typ_of: ctyp -> typ |
17 val ctyp_of: theory -> typ -> ctyp |
28 val ctyp_of: theory -> typ -> ctyp |
|
29 val dest_ctyp: ctyp -> ctyp list |
18 |
30 |
19 (*certified terms*) |
31 (*certified terms*) |
20 type cterm |
|
21 exception CTERM of string * cterm list |
|
22 val rep_cterm: cterm -> {thy: theory, t: term, T: typ, maxidx: int, sorts: sort Ord_List.T} |
32 val rep_cterm: cterm -> {thy: theory, t: term, T: typ, maxidx: int, sorts: sort Ord_List.T} |
23 val crep_cterm: cterm -> {thy: theory, t: term, T: ctyp, maxidx: int, sorts: sort Ord_List.T} |
33 val crep_cterm: cterm -> {thy: theory, t: term, T: ctyp, maxidx: int, sorts: sort Ord_List.T} |
24 val theory_of_cterm: cterm -> theory |
34 val theory_of_cterm: cterm -> theory |
25 val term_of: cterm -> term |
35 val term_of: cterm -> term |
|
36 val ctyp_of_term: cterm -> ctyp |
26 val cterm_of: theory -> term -> cterm |
37 val cterm_of: theory -> term -> cterm |
27 val ctyp_of_term: cterm -> ctyp |
38 val dest_comb: cterm -> cterm * cterm |
|
39 val dest_fun: cterm -> cterm |
|
40 val dest_arg: cterm -> cterm |
|
41 val dest_fun2: cterm -> cterm |
|
42 val dest_arg1: cterm -> cterm |
|
43 val dest_abs: string option -> cterm -> cterm * cterm |
|
44 val apply: cterm -> cterm -> cterm |
|
45 val lambda_name: string * cterm -> cterm -> cterm |
|
46 val lambda: cterm -> cterm -> cterm |
|
47 val adjust_maxidx_cterm: int -> cterm -> cterm |
|
48 val incr_indexes_cterm: int -> cterm -> cterm |
|
49 val match: cterm * cterm -> (ctyp * ctyp) list * (cterm * cterm) list |
|
50 val first_order_match: cterm * cterm -> (ctyp * ctyp) list * (cterm * cterm) list |
28 |
51 |
29 (*theorems*) |
52 (*theorems*) |
30 type thm |
|
31 type conv = cterm -> thm |
|
32 val rep_thm: thm -> |
53 val rep_thm: thm -> |
33 {thy: theory, |
54 {thy: theory, |
34 tags: Properties.T, |
55 tags: Properties.T, |
35 maxidx: int, |
56 maxidx: int, |
36 shyps: sort Ord_List.T, |
57 shyps: sort Ord_List.T, |
43 maxidx: int, |
64 maxidx: int, |
44 shyps: sort Ord_List.T, |
65 shyps: sort Ord_List.T, |
45 hyps: cterm Ord_List.T, |
66 hyps: cterm Ord_List.T, |
46 tpairs: (cterm * cterm) list, |
67 tpairs: (cterm * cterm) list, |
47 prop: cterm} |
68 prop: cterm} |
48 exception THM of string * int * thm list |
69 val fold_terms: (term -> 'a -> 'a) -> thm -> 'a -> 'a |
|
70 val terms_of_tpairs: (term * term) list -> term list |
|
71 val full_prop_of: thm -> term |
49 val theory_of_thm: thm -> theory |
72 val theory_of_thm: thm -> theory |
|
73 val maxidx_of: thm -> int |
|
74 val maxidx_thm: thm -> int -> int |
|
75 val hyps_of: thm -> term list |
50 val prop_of: thm -> term |
76 val prop_of: thm -> term |
|
77 val tpairs_of: thm -> (term * term) list |
51 val concl_of: thm -> term |
78 val concl_of: thm -> term |
52 val prems_of: thm -> term list |
79 val prems_of: thm -> term list |
53 val nprems_of: thm -> int |
80 val nprems_of: thm -> int |
|
81 val no_prems: thm -> bool |
|
82 val major_prem_of: thm -> term |
54 val cprop_of: thm -> cterm |
83 val cprop_of: thm -> cterm |
55 val cprem_of: thm -> int -> cterm |
84 val cprem_of: thm -> int -> cterm |
56 end; |
|
57 |
|
58 signature THM = |
|
59 sig |
|
60 include BASIC_THM |
|
61 val dest_ctyp: ctyp -> ctyp list |
|
62 val dest_comb: cterm -> cterm * cterm |
|
63 val dest_fun: cterm -> cterm |
|
64 val dest_arg: cterm -> cterm |
|
65 val dest_fun2: cterm -> cterm |
|
66 val dest_arg1: cterm -> cterm |
|
67 val dest_abs: string option -> cterm -> cterm * cterm |
|
68 val apply: cterm -> cterm -> cterm |
|
69 val lambda_name: string * cterm -> cterm -> cterm |
|
70 val lambda: cterm -> cterm -> cterm |
|
71 val adjust_maxidx_cterm: int -> cterm -> cterm |
|
72 val incr_indexes_cterm: int -> cterm -> cterm |
|
73 val match: cterm * cterm -> (ctyp * ctyp) list * (cterm * cterm) list |
|
74 val first_order_match: cterm * cterm -> (ctyp * ctyp) list * (cterm * cterm) list |
|
75 val fold_terms: (term -> 'a -> 'a) -> thm -> 'a -> 'a |
|
76 val terms_of_tpairs: (term * term) list -> term list |
|
77 val full_prop_of: thm -> term |
|
78 val maxidx_of: thm -> int |
|
79 val maxidx_thm: thm -> int -> int |
|
80 val hyps_of: thm -> term list |
|
81 val tpairs_of: thm -> (term * term) list |
|
82 val no_prems: thm -> bool |
|
83 val major_prem_of: thm -> term |
|
84 val transfer: theory -> thm -> thm |
85 val transfer: theory -> thm -> thm |
85 val weaken: cterm -> thm -> thm |
86 val weaken: cterm -> thm -> thm |
86 val weaken_sorts: sort list -> cterm -> cterm |
87 val weaken_sorts: sort list -> cterm -> cterm |
87 val extra_shyps: thm -> sort list |
88 val extra_shyps: thm -> sort list |
88 val proof_bodies_of: thm list -> proof_body list |
89 val proof_bodies_of: thm list -> proof_body list |