src/FOL/simpdata.ML
changeset 59498 50b60f501b05
parent 58963 26bf09b95dda
child 59582 0fbed69ff081
equal deleted inserted replaced
59497:0c5cd369a643 59498:50b60f501b05
    21   | _                           => th RS @{thm iff_reflection_T};
    21   | _                           => th RS @{thm iff_reflection_T};
    22 
    22 
    23 (*Replace premises x=y, X<->Y by X==Y*)
    23 (*Replace premises x=y, X<->Y by X==Y*)
    24 fun mk_meta_prems ctxt =
    24 fun mk_meta_prems ctxt =
    25     rule_by_tactic ctxt
    25     rule_by_tactic ctxt
    26       (REPEAT_FIRST (resolve_tac [@{thm meta_eq_to_obj_eq}, @{thm def_imp_iff}]));
    26       (REPEAT_FIRST (resolve_tac ctxt [@{thm meta_eq_to_obj_eq}, @{thm def_imp_iff}]));
    27 
    27 
    28 (*Congruence rules for = or <-> (instead of ==)*)
    28 (*Congruence rules for = or <-> (instead of ==)*)
    29 fun mk_meta_cong ctxt rl =
    29 fun mk_meta_cong ctxt rl =
    30   Drule.zero_var_indexes (mk_meta_eq (mk_meta_prems ctxt rl))
    30   Drule.zero_var_indexes (mk_meta_eq (mk_meta_prems ctxt rl))
    31     handle THM _ =>
    31     handle THM _ =>
   105 (*** Standard simpsets ***)
   105 (*** Standard simpsets ***)
   106 
   106 
   107 val triv_rls = [@{thm TrueI}, @{thm refl}, reflexive_thm, @{thm iff_refl}, @{thm notFalseI}];
   107 val triv_rls = [@{thm TrueI}, @{thm refl}, reflexive_thm, @{thm iff_refl}, @{thm notFalseI}];
   108 
   108 
   109 fun unsafe_solver ctxt =
   109 fun unsafe_solver ctxt =
   110   FIRST' [resolve_tac (triv_rls @ Simplifier.prems_of ctxt),
   110   FIRST' [resolve_tac ctxt (triv_rls @ Simplifier.prems_of ctxt),
   111     assume_tac ctxt,
   111     assume_tac ctxt,
   112     eresolve_tac @{thms FalseE}];
   112     eresolve_tac ctxt @{thms FalseE}];
   113 
   113 
   114 (*No premature instantiation of variables during simplification*)
   114 (*No premature instantiation of variables during simplification*)
   115 fun safe_solver ctxt =
   115 fun safe_solver ctxt =
   116   FIRST' [match_tac ctxt (triv_rls @ Simplifier.prems_of ctxt),
   116   FIRST' [match_tac ctxt (triv_rls @ Simplifier.prems_of ctxt),
   117     eq_assume_tac, ematch_tac ctxt @{thms FalseE}];
   117     eq_assume_tac, ematch_tac ctxt @{thms FalseE}];