| author | blanchet | 
| Mon, 13 Jan 2014 13:24:09 +0100 | |
| changeset 55004 | 96dfb73bb11a | 
| parent 54883 | dd04a8b654fc | 
| child 55048 | ce34a2934386 | 
| permissions | -rw-r--r-- | 
| 5824 | 1 | (* Title: Pure/Isar/method.ML | 
| 2 | Author: Markus Wenzel, TU Muenchen | |
| 3 | ||
| 17110 | 4 | Isar proof methods. | 
| 5824 | 5 | *) | 
| 6 | ||
| 7 | signature METHOD = | |
| 8 | sig | |
| 30508 
958cc116d03b
tuned Method exports: non-pervasive type method (cf. Proof.method), pervasive METHOD combinators;
 wenzelm parents: 
30466diff
changeset | 9 | type method | 
| 32193 
c314b4836031
basic method application: avoid Position.setmp_thread_data_seq, which destroys transaction context;
 wenzelm parents: 
32091diff
changeset | 10 | val apply: (Proof.context -> method) -> Proof.context -> thm list -> cases_tactic | 
| 18227 | 11 | val RAW_METHOD_CASES: (thm list -> cases_tactic) -> method | 
| 17110 | 12 | val RAW_METHOD: (thm list -> tactic) -> method | 
| 18227 | 13 | val METHOD_CASES: (thm list -> cases_tactic) -> method | 
| 17110 | 14 | val METHOD: (thm list -> tactic) -> method | 
| 15 | val fail: method | |
| 16 | val succeed: method | |
| 17 | val insert_tac: thm list -> int -> tactic | |
| 18 | val insert: thm list -> method | |
| 19 | val insert_facts: method | |
| 20 | val SIMPLE_METHOD: tactic -> method | |
| 21592 | 21 | val SIMPLE_METHOD': (int -> tactic) -> method | 
| 22 | val SIMPLE_METHOD'': ((int -> tactic) -> tactic) -> (int -> tactic) -> method | |
| 52059 | 23 | val cheating: Proof.context -> bool -> method | 
| 17110 | 24 | val intro: thm list -> method | 
| 25 | val elim: thm list -> method | |
| 20289 | 26 | val unfold: thm list -> Proof.context -> method | 
| 27 | val fold: thm list -> Proof.context -> method | |
| 54742 
7a86358a3c0b
proper context for basic Simplifier operations: rewrite_rule, rewrite_goals_rule, rewrite_goals_tac etc.;
 wenzelm parents: 
53171diff
changeset | 28 | val atomize: bool -> Proof.context -> method | 
| 17110 | 29 | val this: method | 
| 20289 | 30 | val fact: thm list -> Proof.context -> method | 
| 30234 
7dd251bce291
renamed Method.assumption_tac back to Method.assm_tac -- as assumption_tac it would have to be exactly the tactic behind the assumption method (with facts);
 wenzelm parents: 
30190diff
changeset | 31 | val assm_tac: Proof.context -> int -> tactic | 
| 30567 
cd8e20f86795
close/all_assm_tac: finish all subgoals from left to right (cf. Proof.goal_tac a28d83e903ce) -- NB: ALLGOALS/THEN_ALL_NEW operate from right to left;
 wenzelm parents: 
30544diff
changeset | 32 | val all_assm_tac: Proof.context -> tactic | 
| 20289 | 33 | val assumption: Proof.context -> method | 
| 46466 
61c7214b4885
tuned signature, according to actual usage of these operations;
 wenzelm parents: 
45375diff
changeset | 34 | val rule_trace: bool Config.T | 
| 20289 | 35 | val trace: Proof.context -> thm list -> unit | 
| 54742 
7a86358a3c0b
proper context for basic Simplifier operations: rewrite_rule, rewrite_goals_rule, rewrite_goals_tac etc.;
 wenzelm parents: 
53171diff
changeset | 36 | val rule_tac: Proof.context -> thm list -> thm list -> int -> tactic | 
| 
7a86358a3c0b
proper context for basic Simplifier operations: rewrite_rule, rewrite_goals_rule, rewrite_goals_tac etc.;
 wenzelm parents: 
53171diff
changeset | 37 | val some_rule_tac: Proof.context -> thm list -> thm list -> int -> tactic | 
| 25270 | 38 | val intros_tac: thm list -> thm list -> tactic | 
| 36093 
0880493627ca
Graceful treatment of non-locale subgoals by methods unfold_locales and intro_locales.
 ballarin parents: 
33522diff
changeset | 39 | val try_intros_tac: thm list -> thm list -> tactic | 
| 54742 
7a86358a3c0b
proper context for basic Simplifier operations: rewrite_rule, rewrite_goals_rule, rewrite_goals_tac etc.;
 wenzelm parents: 
53171diff
changeset | 40 | val rule: Proof.context -> thm list -> method | 
| 
7a86358a3c0b
proper context for basic Simplifier operations: rewrite_rule, rewrite_goals_rule, rewrite_goals_tac etc.;
 wenzelm parents: 
53171diff
changeset | 41 | val erule: Proof.context -> int -> thm list -> method | 
| 
7a86358a3c0b
proper context for basic Simplifier operations: rewrite_rule, rewrite_goals_rule, rewrite_goals_tac etc.;
 wenzelm parents: 
53171diff
changeset | 42 | val drule: Proof.context -> int -> thm list -> method | 
| 
7a86358a3c0b
proper context for basic Simplifier operations: rewrite_rule, rewrite_goals_rule, rewrite_goals_tac etc.;
 wenzelm parents: 
53171diff
changeset | 43 | val frule: Proof.context -> int -> thm list -> method | 
| 27235 | 44 | val set_tactic: (thm list -> tactic) -> Proof.context -> Proof.context | 
| 26385 
ae7564661e76
ML runtime compilation: pass position, tuned signature;
 wenzelm parents: 
26291diff
changeset | 45 | val tactic: string * Position.T -> Proof.context -> method | 
| 27235 | 46 | val raw_tactic: string * Position.T -> Proof.context -> method | 
| 27729 | 47 | type src = Args.src | 
| 5824 | 48 | datatype text = | 
| 32193 
c314b4836031
basic method application: avoid Position.setmp_thread_data_seq, which destroys transaction context;
 wenzelm parents: 
32091diff
changeset | 49 | Basic of Proof.context -> method | | 
| 15703 | 50 | Source of src | | 
| 20030 | 51 | Source_i of src | | 
| 5824 | 52 | Then of text list | | 
| 53 | Orelse of text list | | |
| 54 | Try of text | | |
| 19186 | 55 | Repeat1 of text | | 
| 51383 | 56 | Select_Goals of int * text | 
| 54883 
dd04a8b654fc
proper context for norm_hhf and derived operations;
 wenzelm parents: 
54742diff
changeset | 57 | val primitive_text: (Proof.context -> thm -> thm) -> text | 
| 17857 | 58 | val succeed_text: text | 
| 17110 | 59 | val default_text: text | 
| 60 | val this_text: text | |
| 61 | val done_text: text | |
| 17356 
09afdf37cdb3
added cheating, sorry_text (from skip_proofs.ML);
 wenzelm parents: 
17314diff
changeset | 62 | val sorry_text: bool -> text | 
| 32193 
c314b4836031
basic method application: avoid Position.setmp_thread_data_seq, which destroys transaction context;
 wenzelm parents: 
32091diff
changeset | 63 | val finish_text: text option * bool -> text | 
| 27729 | 64 | val print_methods: theory -> unit | 
| 53044 | 65 | val check: theory -> xstring * Position.T -> string | 
| 26892 | 66 | val intern: theory -> xstring -> string | 
| 20289 | 67 | val method: theory -> src -> Proof.context -> method | 
| 68 | val method_i: theory -> src -> Proof.context -> method | |
| 30512 | 69 | val syntax: 'a context_parser -> src -> Proof.context -> 'a * Proof.context | 
| 70 | val setup: binding -> (Proof.context -> method) context_parser -> string -> theory -> theory | |
| 30575 | 71 | val method_setup: bstring * Position.T -> Symbol_Pos.text * Position.T -> string -> | 
| 72 | theory -> theory | |
| 30540 | 73 | type modifier = (Proof.context -> Proof.context) * attribute | 
| 74 | val section: modifier parser list -> thm list context_parser | |
| 75 | val sections: modifier parser list -> thm list list context_parser | |
| 49889 
00ea087e83d8
more method position information, notably finished_pos after end of previous text;
 wenzelm parents: 
49866diff
changeset | 76 | type text_range = text * Position.range | 
| 
00ea087e83d8
more method position information, notably finished_pos after end of previous text;
 wenzelm parents: 
49866diff
changeset | 77 | val parse: text_range parser | 
| 
00ea087e83d8
more method position information, notably finished_pos after end of previous text;
 wenzelm parents: 
49866diff
changeset | 78 | val text: text_range option -> text option | 
| 
00ea087e83d8
more method position information, notably finished_pos after end of previous text;
 wenzelm parents: 
49866diff
changeset | 79 | val position: text_range option -> Position.T | 
| 5824 | 80 | end; | 
| 81 | ||
| 82 | structure Method: METHOD = | |
| 83 | struct | |
| 84 | ||
| 12324 
5db4b4596d1a
rule context and attributes moved to rule_context.ML;
 wenzelm parents: 
12311diff
changeset | 85 | (** proof methods **) | 
| 
5db4b4596d1a
rule context and attributes moved to rule_context.ML;
 wenzelm parents: 
12311diff
changeset | 86 | |
| 17110 | 87 | (* datatype method *) | 
| 11731 | 88 | |
| 18227 | 89 | datatype method = Meth of thm list -> cases_tactic; | 
| 11731 | 90 | |
| 32193 
c314b4836031
basic method application: avoid Position.setmp_thread_data_seq, which destroys transaction context;
 wenzelm parents: 
32091diff
changeset | 91 | fun apply meth ctxt = let val Meth m = meth ctxt in m end; | 
| 11731 | 92 | |
| 17756 | 93 | val RAW_METHOD_CASES = Meth; | 
| 11731 | 94 | |
| 17110 | 95 | fun RAW_METHOD tac = RAW_METHOD_CASES (NO_CASES o tac); | 
| 12144 | 96 | |
| 17110 | 97 | fun METHOD_CASES tac = RAW_METHOD_CASES (fn facts => | 
| 21687 | 98 | Seq.THEN (ALLGOALS Goal.conjunction_tac, tac facts)); | 
| 8372 | 99 | |
| 21687 | 100 | fun METHOD tac = RAW_METHOD (fn facts => ALLGOALS Goal.conjunction_tac THEN tac facts); | 
| 5824 | 101 | |
| 102 | val fail = METHOD (K no_tac); | |
| 103 | val succeed = METHOD (K all_tac); | |
| 104 | ||
| 105 | ||
| 17110 | 106 | (* insert facts *) | 
| 7419 | 107 | |
| 108 | local | |
| 5824 | 109 | |
| 21579 | 110 | fun cut_rule_tac rule = | 
| 52732 | 111 | rtac (Drule.forall_intr_vars rule COMP_INCR revcut_rl); | 
| 6981 | 112 | |
| 7419 | 113 | in | 
| 5824 | 114 | |
| 51552 
c713c9505f68
clarified Skip_Proof.cheat_tac: more standard tactic;
 wenzelm parents: 
51383diff
changeset | 115 | fun insert_tac [] _ = all_tac | 
| 7419 | 116 | | insert_tac facts i = EVERY (map (fn th => cut_rule_tac th i) facts); | 
| 6981 | 117 | |
| 7555 | 118 | val insert_facts = METHOD (ALLGOALS o insert_tac); | 
| 7664 | 119 | fun insert thms = METHOD (fn _ => ALLGOALS (insert_tac thms)); | 
| 7419 | 120 | |
| 9706 | 121 | fun SIMPLE_METHOD tac = METHOD (fn facts => ALLGOALS (insert_tac facts) THEN tac); | 
| 21592 | 122 | fun SIMPLE_METHOD'' quant tac = METHOD (fn facts => quant (insert_tac facts THEN' tac)); | 
| 123 | val SIMPLE_METHOD' = SIMPLE_METHOD'' HEADGOAL; | |
| 9706 | 124 | |
| 12324 
5db4b4596d1a
rule context and attributes moved to rule_context.ML;
 wenzelm parents: 
12311diff
changeset | 125 | end; | 
| 
5db4b4596d1a
rule context and attributes moved to rule_context.ML;
 wenzelm parents: 
12311diff
changeset | 126 | |
| 9706 | 127 | |
| 17356 
09afdf37cdb3
added cheating, sorry_text (from skip_proofs.ML);
 wenzelm parents: 
17314diff
changeset | 128 | (* cheating *) | 
| 
09afdf37cdb3
added cheating, sorry_text (from skip_proofs.ML);
 wenzelm parents: 
17314diff
changeset | 129 | |
| 52059 | 130 | fun cheating ctxt int = METHOD (fn _ => fn st => | 
| 131 | if int orelse Config.get ctxt quick_and_dirty then | |
| 51552 
c713c9505f68
clarified Skip_Proof.cheat_tac: more standard tactic;
 wenzelm parents: 
51383diff
changeset | 132 | ALLGOALS Skip_Proof.cheat_tac st | 
| 
c713c9505f68
clarified Skip_Proof.cheat_tac: more standard tactic;
 wenzelm parents: 
51383diff
changeset | 133 | else error "Cheating requires quick_and_dirty mode!"); | 
| 17356 
09afdf37cdb3
added cheating, sorry_text (from skip_proofs.ML);
 wenzelm parents: 
17314diff
changeset | 134 | |
| 
09afdf37cdb3
added cheating, sorry_text (from skip_proofs.ML);
 wenzelm parents: 
17314diff
changeset | 135 | |
| 17110 | 136 | (* unfold intro/elim rules *) | 
| 137 | ||
| 52732 | 138 | fun intro ths = SIMPLE_METHOD' (CHANGED_PROP o REPEAT_ALL_NEW (match_tac ths)); | 
| 139 | fun elim ths = SIMPLE_METHOD' (CHANGED_PROP o REPEAT_ALL_NEW (ematch_tac ths)); | |
| 17110 | 140 | |
| 141 | ||
| 12384 | 142 | (* unfold/fold definitions *) | 
| 143 | ||
| 35624 | 144 | fun unfold_meth ths ctxt = SIMPLE_METHOD (CHANGED_PROP (Local_Defs.unfold_tac ctxt ths)); | 
| 145 | fun fold_meth ths ctxt = SIMPLE_METHOD (CHANGED_PROP (Local_Defs.fold_tac ctxt ths)); | |
| 6532 | 146 | |
| 12384 | 147 | |
| 12829 | 148 | (* atomize rule statements *) | 
| 149 | ||
| 54742 
7a86358a3c0b
proper context for basic Simplifier operations: rewrite_rule, rewrite_goals_rule, rewrite_goals_tac etc.;
 wenzelm parents: 
53171diff
changeset | 150 | fun atomize false ctxt = | 
| 
7a86358a3c0b
proper context for basic Simplifier operations: rewrite_rule, rewrite_goals_rule, rewrite_goals_tac etc.;
 wenzelm parents: 
53171diff
changeset | 151 | SIMPLE_METHOD' (CHANGED_PROP o Object_Logic.atomize_prems_tac ctxt) | 
| 
7a86358a3c0b
proper context for basic Simplifier operations: rewrite_rule, rewrite_goals_rule, rewrite_goals_tac etc.;
 wenzelm parents: 
53171diff
changeset | 152 | | atomize true ctxt = | 
| 
7a86358a3c0b
proper context for basic Simplifier operations: rewrite_rule, rewrite_goals_rule, rewrite_goals_tac etc.;
 wenzelm parents: 
53171diff
changeset | 153 | RAW_METHOD (K (HEADGOAL (CHANGED_PROP o Object_Logic.full_atomize_tac ctxt))); | 
| 12829 | 154 | |
| 155 | ||
| 18039 | 156 | (* this -- resolve facts directly *) | 
| 12384 | 157 | |
| 52732 | 158 | val this = METHOD (EVERY o map (HEADGOAL o rtac)); | 
| 9484 | 159 | |
| 160 | ||
| 18039 | 161 | (* fact -- composition by facts from context *) | 
| 162 | ||
| 42360 | 163 | fun fact [] ctxt = SIMPLE_METHOD' (Proof_Context.some_fact_tac ctxt) | 
| 54742 
7a86358a3c0b
proper context for basic Simplifier operations: rewrite_rule, rewrite_goals_rule, rewrite_goals_tac etc.;
 wenzelm parents: 
53171diff
changeset | 164 | | fact rules ctxt = SIMPLE_METHOD' (Proof_Context.fact_tac ctxt rules); | 
| 18039 | 165 | |
| 166 | ||
| 17110 | 167 | (* assumption *) | 
| 7419 | 168 | |
| 169 | local | |
| 170 | ||
| 19778 | 171 | fun cond_rtac cond rule = SUBGOAL (fn (prop, i) => | 
| 172 | if cond (Logic.strip_assums_concl prop) | |
| 52732 | 173 | then rtac rule i else no_tac); | 
| 7419 | 174 | |
| 29857 
2cc976ed8a3c
FindTheorems: add solves feature; tidy up const name subsettin; patch by Timothy Bourke
 kleing parents: 
29301diff
changeset | 175 | in | 
| 
2cc976ed8a3c
FindTheorems: add solves feature; tidy up const name subsettin; patch by Timothy Bourke
 kleing parents: 
29301diff
changeset | 176 | |
| 30234 
7dd251bce291
renamed Method.assumption_tac back to Method.assm_tac -- as assumption_tac it would have to be exactly the tactic behind the assumption method (with facts);
 wenzelm parents: 
30190diff
changeset | 177 | fun assm_tac ctxt = | 
| 17110 | 178 | assume_tac APPEND' | 
| 23349 | 179 | Goal.assume_rule_tac ctxt APPEND' | 
| 19778 | 180 | cond_rtac (can Logic.dest_equals) Drule.reflexive_thm APPEND' | 
| 181 | cond_rtac (can Logic.dest_term) Drule.termI; | |
| 17110 | 182 | |
| 49846 
8fae089f5a0c
refined Proof.the_finished_goal with more informative error;
 wenzelm parents: 
48992diff
changeset | 183 | fun all_assm_tac ctxt = | 
| 
8fae089f5a0c
refined Proof.the_finished_goal with more informative error;
 wenzelm parents: 
48992diff
changeset | 184 | let | 
| 
8fae089f5a0c
refined Proof.the_finished_goal with more informative error;
 wenzelm parents: 
48992diff
changeset | 185 | fun tac i st = | 
| 
8fae089f5a0c
refined Proof.the_finished_goal with more informative error;
 wenzelm parents: 
48992diff
changeset | 186 | if i > Thm.nprems_of st then all_tac st | 
| 
8fae089f5a0c
refined Proof.the_finished_goal with more informative error;
 wenzelm parents: 
48992diff
changeset | 187 | else ((assm_tac ctxt i THEN tac i) ORELSE tac (i + 1)) st; | 
| 
8fae089f5a0c
refined Proof.the_finished_goal with more informative error;
 wenzelm parents: 
48992diff
changeset | 188 | in tac 1 end; | 
| 30567 
cd8e20f86795
close/all_assm_tac: finish all subgoals from left to right (cf. Proof.goal_tac a28d83e903ce) -- NB: ALLGOALS/THEN_ALL_NEW operate from right to left;
 wenzelm parents: 
30544diff
changeset | 189 | |
| 23349 | 190 | fun assumption ctxt = METHOD (HEADGOAL o | 
| 30234 
7dd251bce291
renamed Method.assumption_tac back to Method.assm_tac -- as assumption_tac it would have to be exactly the tactic behind the assumption method (with facts);
 wenzelm parents: 
30190diff
changeset | 191 | (fn [] => assm_tac ctxt | 
| 23349 | 192 | | [fact] => solve_tac [fact] | 
| 193 | | _ => K no_tac)); | |
| 194 | ||
| 49846 
8fae089f5a0c
refined Proof.the_finished_goal with more informative error;
 wenzelm parents: 
48992diff
changeset | 195 | fun finish immed ctxt = | 
| 
8fae089f5a0c
refined Proof.the_finished_goal with more informative error;
 wenzelm parents: 
48992diff
changeset | 196 | METHOD (K ((if immed then all_assm_tac ctxt else all_tac) THEN flexflex_tac)); | 
| 7419 | 197 | |
| 198 | end; | |
| 199 | ||
| 200 | ||
| 17110 | 201 | (* rule etc. -- single-step refinements *) | 
| 12347 | 202 | |
| 42616 
92715b528e78
added Attrib.setup_config_XXX conveniences, with implicit setup of the background theory;
 wenzelm parents: 
42380diff
changeset | 203 | val rule_trace = Attrib.setup_config_bool (Binding.name "rule_trace") (fn _ => false); | 
| 12347 | 204 | |
| 17110 | 205 | fun trace ctxt rules = | 
| 41379 | 206 | if Config.get ctxt rule_trace andalso not (null rules) then | 
| 51584 | 207 | Pretty.big_list "rules:" (map (Display.pretty_thm_item ctxt) rules) | 
| 21962 | 208 | |> Pretty.string_of |> tracing | 
| 209 | else (); | |
| 12347 | 210 | |
| 211 | local | |
| 212 | ||
| 54742 
7a86358a3c0b
proper context for basic Simplifier operations: rewrite_rule, rewrite_goals_rule, rewrite_goals_tac etc.;
 wenzelm parents: 
53171diff
changeset | 213 | fun gen_rule_tac tac ctxt rules facts = | 
| 18841 | 214 | (fn i => fn st => | 
| 215 | if null facts then tac rules i st | |
| 216 | else Seq.maps (fn rule => (tac o single) rule i st) (Drule.multi_resolves facts rules)) | |
| 54742 
7a86358a3c0b
proper context for basic Simplifier operations: rewrite_rule, rewrite_goals_rule, rewrite_goals_tac etc.;
 wenzelm parents: 
53171diff
changeset | 217 | THEN_ALL_NEW Goal.norm_hhf_tac ctxt; | 
| 7130 | 218 | |
| 54742 
7a86358a3c0b
proper context for basic Simplifier operations: rewrite_rule, rewrite_goals_rule, rewrite_goals_tac etc.;
 wenzelm parents: 
53171diff
changeset | 219 | fun gen_arule_tac tac ctxt j rules facts = | 
| 
7a86358a3c0b
proper context for basic Simplifier operations: rewrite_rule, rewrite_goals_rule, rewrite_goals_tac etc.;
 wenzelm parents: 
53171diff
changeset | 220 | EVERY' (gen_rule_tac tac ctxt rules facts :: replicate j assume_tac); | 
| 10744 | 221 | |
| 54742 
7a86358a3c0b
proper context for basic Simplifier operations: rewrite_rule, rewrite_goals_rule, rewrite_goals_tac etc.;
 wenzelm parents: 
53171diff
changeset | 222 | fun gen_some_rule_tac tac ctxt arg_rules facts = SUBGOAL (fn (goal, i) => | 
| 11785 | 223 | let | 
| 224 | val rules = | |
| 225 | if not (null arg_rules) then arg_rules | |
| 33369 | 226 | else flat (Context_Rules.find_rules false facts goal ctxt) | 
| 54742 
7a86358a3c0b
proper context for basic Simplifier operations: rewrite_rule, rewrite_goals_rule, rewrite_goals_tac etc.;
 wenzelm parents: 
53171diff
changeset | 227 | in trace ctxt rules; tac ctxt rules facts i end); | 
| 10309 | 228 | |
| 54742 
7a86358a3c0b
proper context for basic Simplifier operations: rewrite_rule, rewrite_goals_rule, rewrite_goals_tac etc.;
 wenzelm parents: 
53171diff
changeset | 229 | fun meth tac x y = METHOD (HEADGOAL o tac x y); | 
| 
7a86358a3c0b
proper context for basic Simplifier operations: rewrite_rule, rewrite_goals_rule, rewrite_goals_tac etc.;
 wenzelm parents: 
53171diff
changeset | 230 | fun meth' tac x y z = METHOD (HEADGOAL o tac x y z); | 
| 8220 | 231 | |
| 7419 | 232 | in | 
| 233 | ||
| 52732 | 234 | val rule_tac = gen_rule_tac resolve_tac; | 
| 10744 | 235 | val rule = meth rule_tac; | 
| 236 | val some_rule_tac = gen_some_rule_tac rule_tac; | |
| 54742 
7a86358a3c0b
proper context for basic Simplifier operations: rewrite_rule, rewrite_goals_rule, rewrite_goals_tac etc.;
 wenzelm parents: 
53171diff
changeset | 237 | val some_rule = meth some_rule_tac; | 
| 10744 | 238 | |
| 52732 | 239 | val erule = meth' (gen_arule_tac eresolve_tac); | 
| 240 | val drule = meth' (gen_arule_tac dresolve_tac); | |
| 241 | val frule = meth' (gen_arule_tac forward_tac); | |
| 5824 | 242 | |
| 7419 | 243 | end; | 
| 244 | ||
| 245 | ||
| 25270 | 246 | (* intros_tac -- pervasive search spanned by intro rules *) | 
| 247 | ||
| 36093 
0880493627ca
Graceful treatment of non-locale subgoals by methods unfold_locales and intro_locales.
 ballarin parents: 
33522diff
changeset | 248 | fun gen_intros_tac goals intros facts = | 
| 
0880493627ca
Graceful treatment of non-locale subgoals by methods unfold_locales and intro_locales.
 ballarin parents: 
33522diff
changeset | 249 | goals (insert_tac facts THEN' | 
| 25270 | 250 | REPEAT_ALL_NEW (resolve_tac intros)) | 
| 251 | THEN Tactic.distinct_subgoals_tac; | |
| 252 | ||
| 36093 
0880493627ca
Graceful treatment of non-locale subgoals by methods unfold_locales and intro_locales.
 ballarin parents: 
33522diff
changeset | 253 | val intros_tac = gen_intros_tac ALLGOALS; | 
| 
0880493627ca
Graceful treatment of non-locale subgoals by methods unfold_locales and intro_locales.
 ballarin parents: 
33522diff
changeset | 254 | val try_intros_tac = gen_intros_tac TRYALL; | 
| 25270 | 255 | |
| 37216 
3165bc303f66
modernized some structure names, keeping a few legacy aliases;
 wenzelm parents: 
37198diff
changeset | 256 | |
| 8351 | 257 | (* ML tactics *) | 
| 258 | ||
| 37216 
3165bc303f66
modernized some structure names, keeping a few legacy aliases;
 wenzelm parents: 
37198diff
changeset | 259 | structure ML_Tactic = Proof_Data | 
| 26472 
9afdd61cf528
ml_tactic: non-critical version via proof data and thread data;
 wenzelm parents: 
26463diff
changeset | 260 | ( | 
| 27235 | 261 | type T = thm list -> tactic; | 
| 26472 
9afdd61cf528
ml_tactic: non-critical version via proof data and thread data;
 wenzelm parents: 
26463diff
changeset | 262 | fun init _ = undefined; | 
| 
9afdd61cf528
ml_tactic: non-critical version via proof data and thread data;
 wenzelm parents: 
26463diff
changeset | 263 | ); | 
| 
9afdd61cf528
ml_tactic: non-critical version via proof data and thread data;
 wenzelm parents: 
26463diff
changeset | 264 | |
| 37216 
3165bc303f66
modernized some structure names, keeping a few legacy aliases;
 wenzelm parents: 
37198diff
changeset | 265 | val set_tactic = ML_Tactic.put; | 
| 8351 | 266 | |
| 26472 
9afdd61cf528
ml_tactic: non-critical version via proof data and thread data;
 wenzelm parents: 
26463diff
changeset | 267 | fun ml_tactic (txt, pos) ctxt = | 
| 
9afdd61cf528
ml_tactic: non-critical version via proof data and thread data;
 wenzelm parents: 
26463diff
changeset | 268 | let | 
| 
9afdd61cf528
ml_tactic: non-critical version via proof data and thread data;
 wenzelm parents: 
26463diff
changeset | 269 | val ctxt' = ctxt |> Context.proof_map | 
| 27235 | 270 | (ML_Context.expression pos | 
| 271 | "fun tactic (facts: thm list) : tactic" | |
| 37198 
3af985b10550
replaced ML_Lex.read_antiq by more concise ML_Lex.read, which includes full read/report with explicit position information;
 wenzelm parents: 
36959diff
changeset | 272 | "Context.map_proof (Method.set_tactic tactic)" (ML_Lex.read pos txt)); | 
| 37216 
3165bc303f66
modernized some structure names, keeping a few legacy aliases;
 wenzelm parents: 
37198diff
changeset | 273 | in Context.setmp_thread_data (SOME (Context.Proof ctxt)) (ML_Tactic.get ctxt') end; | 
| 23425 | 274 | |
| 275 | fun tactic txt ctxt = METHOD (ml_tactic txt ctxt); | |
| 276 | fun raw_tactic txt ctxt = RAW_METHOD (ml_tactic txt ctxt); | |
| 8351 | 277 | |
| 278 | ||
| 5824 | 279 | |
| 17110 | 280 | (** method syntax **) | 
| 281 | ||
| 282 | (* method text *) | |
| 283 | ||
| 284 | type src = Args.src; | |
| 5824 | 285 | |
| 17110 | 286 | datatype text = | 
| 32193 
c314b4836031
basic method application: avoid Position.setmp_thread_data_seq, which destroys transaction context;
 wenzelm parents: 
32091diff
changeset | 287 | Basic of Proof.context -> method | | 
| 17110 | 288 | Source of src | | 
| 20030 | 289 | Source_i of src | | 
| 17110 | 290 | Then of text list | | 
| 291 | Orelse of text list | | |
| 292 | Try of text | | |
| 19186 | 293 | Repeat1 of text | | 
| 51383 | 294 | Select_Goals of int * text; | 
| 17110 | 295 | |
| 54883 
dd04a8b654fc
proper context for norm_hhf and derived operations;
 wenzelm parents: 
54742diff
changeset | 296 | fun primitive_text r = Basic (SIMPLE_METHOD o PRIMITIVE o r); | 
| 32193 
c314b4836031
basic method application: avoid Position.setmp_thread_data_seq, which destroys transaction context;
 wenzelm parents: 
32091diff
changeset | 297 | val succeed_text = Basic (K succeed); | 
| 17110 | 298 | val default_text = Source (Args.src (("default", []), Position.none));
 | 
| 32193 
c314b4836031
basic method application: avoid Position.setmp_thread_data_seq, which destroys transaction context;
 wenzelm parents: 
32091diff
changeset | 299 | val this_text = Basic (K this); | 
| 
c314b4836031
basic method application: avoid Position.setmp_thread_data_seq, which destroys transaction context;
 wenzelm parents: 
32091diff
changeset | 300 | val done_text = Basic (K (SIMPLE_METHOD all_tac)); | 
| 52059 | 301 | fun sorry_text int = Basic (fn ctxt => cheating ctxt int); | 
| 17110 | 302 | |
| 49846 
8fae089f5a0c
refined Proof.the_finished_goal with more informative error;
 wenzelm parents: 
48992diff
changeset | 303 | fun finish_text (NONE, immed) = Basic (finish immed) | 
| 
8fae089f5a0c
refined Proof.the_finished_goal with more informative error;
 wenzelm parents: 
48992diff
changeset | 304 | | finish_text (SOME txt, immed) = Then [txt, Basic (finish immed)]; | 
| 17110 | 305 | |
| 306 | ||
| 307 | (* method definitions *) | |
| 5824 | 308 | |
| 33522 | 309 | structure Methods = Theory_Data | 
| 22846 | 310 | ( | 
| 33095 
bbd52d2f8696
renamed NameSpace to Name_Space -- also to emphasize its subtle change in semantics;
 wenzelm parents: 
33092diff
changeset | 311 | type T = ((src -> Proof.context -> method) * string) Name_Space.table; | 
| 33159 | 312 | val empty : T = Name_Space.empty_table "method"; | 
| 16448 | 313 | val extend = I; | 
| 33522 | 314 | fun merge data : T = Name_Space.merge_tables data; | 
| 22846 | 315 | ); | 
| 5824 | 316 | |
| 22846 | 317 | fun print_methods thy = | 
| 318 | let | |
| 42360 | 319 | val ctxt = Proof_Context.init_global thy; | 
| 24116 | 320 | val meths = Methods.get thy; | 
| 50301 | 321 | fun prt_meth (name, (_, "")) = Pretty.mark_str name | 
| 42813 
6c841fa92fa2
optional description for 'attribute_setup' and 'method_setup';
 wenzelm parents: 
42616diff
changeset | 322 | | prt_meth (name, (_, comment)) = | 
| 50301 | 323 | Pretty.block | 
| 324 | (Pretty.mark_str name :: Pretty.str ":" :: Pretty.brk 2 :: Pretty.text comment); | |
| 22846 | 325 | in | 
| 42358 
b47d41d9f4b5
Name_Space: proper configuration options long_names, short_names, unique_names instead of former unsynchronized references;
 wenzelm parents: 
41379diff
changeset | 326 | [Pretty.big_list "methods:" (map prt_meth (Name_Space.extern_table ctxt meths))] | 
| 22846 | 327 | |> Pretty.chunks |> Pretty.writeln | 
| 328 | end; | |
| 7611 | 329 | |
| 33092 
c859019d3ac5
eliminated separate stamp -- NameSpace.define/merge etc. ensure uniqueness already;
 wenzelm parents: 
32969diff
changeset | 330 | fun add_method name meth comment thy = thy | 
| 47005 
421760a1efe7
maintain generic context naming in structure Name_Space (NB: empty = default_naming, init = local_naming);
 wenzelm parents: 
46775diff
changeset | 331 | |> Methods.map (Name_Space.define (Context.Theory thy) true (name, (meth, comment)) #> snd); | 
| 31304 | 332 | |
| 5824 | 333 | |
| 334 | (* get methods *) | |
| 335 | ||
| 53044 | 336 | fun check thy = #1 o Name_Space.check (Context.Theory thy) (Methods.get thy); | 
| 337 | ||
| 33095 
bbd52d2f8696
renamed NameSpace to Name_Space -- also to emphasize its subtle change in semantics;
 wenzelm parents: 
33092diff
changeset | 338 | val intern = Name_Space.intern o #1 o Methods.get; | 
| 26892 | 339 | |
| 20030 | 340 | fun method_i thy = | 
| 5824 | 341 | let | 
| 42380 | 342 | val (space, tab) = Methods.get thy; | 
| 5884 | 343 | fun meth src = | 
| 20030 | 344 | let val ((name, _), pos) = Args.dest_src src in | 
| 42380 | 345 | (case Symtab.lookup tab name of | 
| 48992 | 346 |           NONE => error ("Unknown proof method: " ^ quote name ^ Position.here pos)
 | 
| 42380 | 347 | | SOME (mth, _) => (Position.report pos (Name_Space.markup space name); mth src)) | 
| 5824 | 348 | end; | 
| 349 | in meth end; | |
| 350 | ||
| 45228 | 351 | fun method thy = method_i thy o Args.map_name (intern thy); | 
| 20030 | 352 | |
| 5824 | 353 | |
| 30512 | 354 | (* method setup *) | 
| 355 | ||
| 356 | fun syntax scan = Args.context_syntax "method" scan; | |
| 357 | ||
| 31304 | 358 | fun setup name scan = | 
| 359 | add_method name | |
| 360 | (fn src => fn ctxt => let val (m, ctxt') = syntax scan src ctxt in m ctxt' end); | |
| 17356 
09afdf37cdb3
added cheating, sorry_text (from skip_proofs.ML);
 wenzelm parents: 
17314diff
changeset | 361 | |
| 26385 
ae7564661e76
ML runtime compilation: pass position, tuned signature;
 wenzelm parents: 
26291diff
changeset | 362 | fun method_setup name (txt, pos) cmt = | 
| 26472 
9afdd61cf528
ml_tactic: non-critical version via proof data and thread data;
 wenzelm parents: 
26463diff
changeset | 363 | Context.theory_map (ML_Context.expression pos | 
| 30544 | 364 | "val (name, scan, comment): binding * (Proof.context -> Proof.method) context_parser * string" | 
| 365 | "Context.map_theory (Method.setup name scan comment)" | |
| 37198 
3af985b10550
replaced ML_Lex.read_antiq by more concise ML_Lex.read, which includes full read/report with explicit position information;
 wenzelm parents: 
36959diff
changeset | 366 |     (ML_Lex.read Position.none ("(" ^ ML_Syntax.make_binding name ^ ", ") @
 | 
| 
3af985b10550
replaced ML_Lex.read_antiq by more concise ML_Lex.read, which includes full read/report with explicit position information;
 wenzelm parents: 
36959diff
changeset | 367 | ML_Lex.read pos txt @ | 
| 
3af985b10550
replaced ML_Lex.read_antiq by more concise ML_Lex.read, which includes full read/report with explicit position information;
 wenzelm parents: 
36959diff
changeset | 368 |       ML_Lex.read Position.none (", " ^ ML_Syntax.print_string cmt ^ ")")));
 | 
| 17356 
09afdf37cdb3
added cheating, sorry_text (from skip_proofs.ML);
 wenzelm parents: 
17314diff
changeset | 369 | |
| 
09afdf37cdb3
added cheating, sorry_text (from skip_proofs.ML);
 wenzelm parents: 
17314diff
changeset | 370 | |
| 5884 | 371 | |
| 17110 | 372 | (** concrete syntax **) | 
| 5824 | 373 | |
| 5884 | 374 | (* sections *) | 
| 5824 | 375 | |
| 20289 | 376 | type modifier = (Proof.context -> Proof.context) * attribute; | 
| 7268 | 377 | |
| 378 | local | |
| 379 | ||
| 24010 
2ef318813e1a
method section scanners: added [[declaration]] syntax, ignore sid-effects of thms;
 wenzelm parents: 
23937diff
changeset | 380 | fun thms ss = Scan.repeat (Scan.unless (Scan.lift (Scan.first ss)) Attrib.multi_thm) >> flat; | 
| 46775 
6287653e63ec
canonical argument order for attribute application;
 wenzelm parents: 
46466diff
changeset | 381 | fun app (f, att) ths context = fold_map (Thm.apply_attribute att) ths (Context.map_proof f context); | 
| 5824 | 382 | |
| 30540 | 383 | in | 
| 384 | ||
| 24022 | 385 | fun section ss = Scan.depend (fn context => (Scan.first ss -- Scan.pass context (thms ss)) :|-- | 
| 46775 
6287653e63ec
canonical argument order for attribute application;
 wenzelm parents: 
46466diff
changeset | 386 | (fn (m, ths) => Scan.succeed (swap (app m ths context)))); | 
| 5884 | 387 | |
| 30540 | 388 | fun sections ss = Scan.repeat (section ss); | 
| 5824 | 389 | |
| 7268 | 390 | end; | 
| 391 | ||
| 5824 | 392 | |
| 30515 | 393 | (* extra rule methods *) | 
| 394 | ||
| 54742 
7a86358a3c0b
proper context for basic Simplifier operations: rewrite_rule, rewrite_goals_rule, rewrite_goals_tac etc.;
 wenzelm parents: 
53171diff
changeset | 395 | fun xrule_meth meth = | 
| 36950 | 396 | Scan.lift (Scan.optional (Args.parens Parse.nat) 0) -- Attrib.thms >> | 
| 54742 
7a86358a3c0b
proper context for basic Simplifier operations: rewrite_rule, rewrite_goals_rule, rewrite_goals_tac etc.;
 wenzelm parents: 
53171diff
changeset | 397 | (fn (n, ths) => fn ctxt => meth ctxt n ths); | 
| 30515 | 398 | |
| 399 | ||
| 27813 
96fbe385a0d0
unified Args.T with OuterLex.token, renamed some operations;
 wenzelm parents: 
27751diff
changeset | 400 | (* outer parser *) | 
| 
96fbe385a0d0
unified Args.T with OuterLex.token, renamed some operations;
 wenzelm parents: 
27751diff
changeset | 401 | |
| 
96fbe385a0d0
unified Args.T with OuterLex.token, renamed some operations;
 wenzelm parents: 
27751diff
changeset | 402 | fun is_symid_meth s = | 
| 36959 
f5417836dbea
renamed structure OuterLex to Token and type token to Token.T, keeping legacy aliases for some time;
 wenzelm parents: 
36950diff
changeset | 403 | s <> "|" andalso s <> "?" andalso s <> "+" andalso Token.ident_or_symbolic s; | 
| 27813 
96fbe385a0d0
unified Args.T with OuterLex.token, renamed some operations;
 wenzelm parents: 
27751diff
changeset | 404 | |
| 
96fbe385a0d0
unified Args.T with OuterLex.token, renamed some operations;
 wenzelm parents: 
27751diff
changeset | 405 | local | 
| 
96fbe385a0d0
unified Args.T with OuterLex.token, renamed some operations;
 wenzelm parents: 
27751diff
changeset | 406 | |
| 
96fbe385a0d0
unified Args.T with OuterLex.token, renamed some operations;
 wenzelm parents: 
27751diff
changeset | 407 | fun meth4 x = | 
| 36950 | 408 | (Parse.position (Parse.xname >> rpair []) >> (Source o Args.src) || | 
| 409 |   Parse.$$$ "(" |-- Parse.!!! (meth0 --| Parse.$$$ ")")) x
 | |
| 27813 
96fbe385a0d0
unified Args.T with OuterLex.token, renamed some operations;
 wenzelm parents: 
27751diff
changeset | 410 | and meth3 x = | 
| 36950 | 411 | (meth4 --| Parse.$$$ "?" >> Try || | 
| 412 | meth4 --| Parse.$$$ "+" >> Repeat1 || | |
| 51383 | 413 | meth4 -- (Parse.$$$ "[" |-- Scan.optional Parse.nat 1 --| Parse.$$$ "]") | 
| 414 | >> (Select_Goals o swap) || | |
| 27813 
96fbe385a0d0
unified Args.T with OuterLex.token, renamed some operations;
 wenzelm parents: 
27751diff
changeset | 415 | meth4) x | 
| 
96fbe385a0d0
unified Args.T with OuterLex.token, renamed some operations;
 wenzelm parents: 
27751diff
changeset | 416 | and meth2 x = | 
| 36950 | 417 | (Parse.position (Parse.xname -- Args.parse1 is_symid_meth) >> (Source o Args.src) || | 
| 27813 
96fbe385a0d0
unified Args.T with OuterLex.token, renamed some operations;
 wenzelm parents: 
27751diff
changeset | 418 | meth3) x | 
| 36950 | 419 | and meth1 x = (Parse.enum1 "," meth2 >> (fn [m] => m | ms => Then ms)) x | 
| 420 | and meth0 x = (Parse.enum1 "|" meth1 >> (fn [m] => m | ms => Orelse ms)) x; | |
| 27813 
96fbe385a0d0
unified Args.T with OuterLex.token, renamed some operations;
 wenzelm parents: 
27751diff
changeset | 421 | |
| 49866 | 422 | in | 
| 423 | ||
| 424 | val parse = | |
| 49889 
00ea087e83d8
more method position information, notably finished_pos after end of previous text;
 wenzelm parents: 
49866diff
changeset | 425 | Scan.trace meth3 >> (fn (m, toks) => (m, Token.position_range_of toks)); | 
| 49866 | 426 | |
| 427 | end; | |
| 428 | ||
| 429 | ||
| 430 | (* text position *) | |
| 431 | ||
| 49889 
00ea087e83d8
more method position information, notably finished_pos after end of previous text;
 wenzelm parents: 
49866diff
changeset | 432 | type text_range = text * Position.range; | 
| 49866 | 433 | |
| 434 | fun text NONE = NONE | |
| 435 | | text (SOME (txt, _)) = SOME txt; | |
| 436 | ||
| 437 | fun position NONE = Position.none | |
| 49889 
00ea087e83d8
more method position information, notably finished_pos after end of previous text;
 wenzelm parents: 
49866diff
changeset | 438 | | position (SOME (_, range)) = Position.set_range range; | 
| 27813 
96fbe385a0d0
unified Args.T with OuterLex.token, renamed some operations;
 wenzelm parents: 
27751diff
changeset | 439 | |
| 
96fbe385a0d0
unified Args.T with OuterLex.token, renamed some operations;
 wenzelm parents: 
27751diff
changeset | 440 | |
| 18708 | 441 | (* theory setup *) | 
| 5824 | 442 | |
| 53171 | 443 | val _ = Theory.setup | 
| 42616 
92715b528e78
added Attrib.setup_config_XXX conveniences, with implicit setup of the background theory;
 wenzelm parents: 
42380diff
changeset | 444 | (setup (Binding.name "fail") (Scan.succeed (K fail)) "force failure" #> | 
| 30515 | 445 | setup (Binding.name "succeed") (Scan.succeed (K succeed)) "succeed" #> | 
| 446 | setup (Binding.name "-") (Scan.succeed (K insert_facts)) | |
| 447 | "do nothing (insert current facts only)" #> | |
| 448 | setup (Binding.name "insert") (Attrib.thms >> (K o insert)) | |
| 449 | "insert theorems, ignoring facts (improper)" #> | |
| 450 | setup (Binding.name "intro") (Attrib.thms >> (K o intro)) | |
| 451 | "repeatedly apply introduction rules" #> | |
| 452 | setup (Binding.name "elim") (Attrib.thms >> (K o elim)) | |
| 453 | "repeatedly apply elimination rules" #> | |
| 454 | setup (Binding.name "unfold") (Attrib.thms >> unfold_meth) "unfold definitions" #> | |
| 455 | setup (Binding.name "fold") (Attrib.thms >> fold_meth) "fold definitions" #> | |
| 54742 
7a86358a3c0b
proper context for basic Simplifier operations: rewrite_rule, rewrite_goals_rule, rewrite_goals_tac etc.;
 wenzelm parents: 
53171diff
changeset | 456 | setup (Binding.name "atomize") (Scan.lift (Args.mode "full") >> atomize) | 
| 30515 | 457 | "present local premises as object-level statements" #> | 
| 54742 
7a86358a3c0b
proper context for basic Simplifier operations: rewrite_rule, rewrite_goals_rule, rewrite_goals_tac etc.;
 wenzelm parents: 
53171diff
changeset | 458 | setup (Binding.name "rule") (Attrib.thms >> (fn ths => fn ctxt => some_rule ctxt ths)) | 
| 
7a86358a3c0b
proper context for basic Simplifier operations: rewrite_rule, rewrite_goals_rule, rewrite_goals_tac etc.;
 wenzelm parents: 
53171diff
changeset | 459 | "apply some intro/elim rule" #> | 
| 30515 | 460 | setup (Binding.name "erule") (xrule_meth erule) "apply rule in elimination manner (improper)" #> | 
| 461 | setup (Binding.name "drule") (xrule_meth drule) "apply rule in destruct manner (improper)" #> | |
| 462 | setup (Binding.name "frule") (xrule_meth frule) "apply rule in forward manner (improper)" #> | |
| 463 | setup (Binding.name "this") (Scan.succeed (K this)) "apply current facts as rules" #> | |
| 464 | setup (Binding.name "fact") (Attrib.thms >> fact) "composition by facts from context" #> | |
| 465 | setup (Binding.name "assumption") (Scan.succeed assumption) | |
| 466 | "proof by assumption, preferring facts" #> | |
| 467 | setup (Binding.name "rename_tac") (Args.goal_spec -- Scan.lift (Scan.repeat1 Args.name) >> | |
| 52732 | 468 | (fn (quant, xs) => K (SIMPLE_METHOD'' quant (rename_tac xs)))) | 
| 30515 | 469 | "rename parameters of goal" #> | 
| 36950 | 470 | setup (Binding.name "rotate_tac") (Args.goal_spec -- Scan.lift (Scan.optional Parse.int 1) >> | 
| 52732 | 471 | (fn (quant, i) => K (SIMPLE_METHOD'' quant (rotate_tac i)))) | 
| 30515 | 472 | "rotate assumptions of goal" #> | 
| 37198 
3af985b10550
replaced ML_Lex.read_antiq by more concise ML_Lex.read, which includes full read/report with explicit position information;
 wenzelm parents: 
36959diff
changeset | 473 | setup (Binding.name "tactic") (Scan.lift Args.name_source_position >> tactic) | 
| 30515 | 474 | "ML tactic as proof method" #> | 
| 37198 
3af985b10550
replaced ML_Lex.read_antiq by more concise ML_Lex.read, which includes full read/report with explicit position information;
 wenzelm parents: 
36959diff
changeset | 475 | setup (Binding.name "raw_tactic") (Scan.lift Args.name_source_position >> raw_tactic) | 
| 53171 | 476 | "ML tactic as raw proof method"); | 
| 5824 | 477 | |
| 478 | ||
| 16145 | 479 | (*final declarations of this structure!*) | 
| 480 | val unfold = unfold_meth; | |
| 481 | val fold = fold_meth; | |
| 482 | ||
| 5824 | 483 | end; | 
| 484 | ||
| 30508 
958cc116d03b
tuned Method exports: non-pervasive type method (cf. Proof.method), pervasive METHOD combinators;
 wenzelm parents: 
30466diff
changeset | 485 | val RAW_METHOD_CASES = Method.RAW_METHOD_CASES; | 
| 
958cc116d03b
tuned Method exports: non-pervasive type method (cf. Proof.method), pervasive METHOD combinators;
 wenzelm parents: 
30466diff
changeset | 486 | val RAW_METHOD = Method.RAW_METHOD; | 
| 
958cc116d03b
tuned Method exports: non-pervasive type method (cf. Proof.method), pervasive METHOD combinators;
 wenzelm parents: 
30466diff
changeset | 487 | val METHOD_CASES = Method.METHOD_CASES; | 
| 
958cc116d03b
tuned Method exports: non-pervasive type method (cf. Proof.method), pervasive METHOD combinators;
 wenzelm parents: 
30466diff
changeset | 488 | val METHOD = Method.METHOD; | 
| 
958cc116d03b
tuned Method exports: non-pervasive type method (cf. Proof.method), pervasive METHOD combinators;
 wenzelm parents: 
30466diff
changeset | 489 | val SIMPLE_METHOD = Method.SIMPLE_METHOD; | 
| 
958cc116d03b
tuned Method exports: non-pervasive type method (cf. Proof.method), pervasive METHOD combinators;
 wenzelm parents: 
30466diff
changeset | 490 | val SIMPLE_METHOD' = Method.SIMPLE_METHOD'; | 
| 
958cc116d03b
tuned Method exports: non-pervasive type method (cf. Proof.method), pervasive METHOD combinators;
 wenzelm parents: 
30466diff
changeset | 491 | val SIMPLE_METHOD'' = Method.SIMPLE_METHOD''; | 
| 
958cc116d03b
tuned Method exports: non-pervasive type method (cf. Proof.method), pervasive METHOD combinators;
 wenzelm parents: 
30466diff
changeset | 492 |