src/HOL/BNF/Tools/bnf_gfp_rec_sugar_tactics.ML
changeset 54924 44373f3560c7
parent 54923 ffed2452f5f6
child 54925 c63223067cab
equal deleted inserted replaced
54923:ffed2452f5f6 54924:44373f3560c7
    13   val mk_primcorec_disc_tac: Proof.context -> thm list -> thm -> int -> int -> thm list list list ->
    13   val mk_primcorec_disc_tac: Proof.context -> thm list -> thm -> int -> int -> thm list list list ->
    14     tactic
    14     tactic
    15   val mk_primcorec_disc_iff_tac: Proof.context -> string list -> thm -> thm -> thm list list ->
    15   val mk_primcorec_disc_iff_tac: Proof.context -> string list -> thm -> thm -> thm list list ->
    16     thm list -> tactic
    16     thm list -> tactic
    17   val mk_primcorec_exhaust_tac: Proof.context -> string list -> int -> thm -> tactic
    17   val mk_primcorec_exhaust_tac: Proof.context -> string list -> int -> thm -> tactic
       
    18   val mk_primcorec_nchotomy_tac: Proof.context -> thm list -> tactic
    18   val mk_primcorec_raw_code_of_ctr_tac: Proof.context -> thm list -> thm list -> thm list ->
    19   val mk_primcorec_raw_code_of_ctr_tac: Proof.context -> thm list -> thm list -> thm list ->
    19     thm list -> int list -> thm list -> thm option -> tactic
    20     thm list -> int list -> thm list -> thm option -> tactic
    20   val mk_primcorec_sel_tac: Proof.context -> thm list -> thm list -> thm list -> thm list ->
    21   val mk_primcorec_sel_tac: Proof.context -> thm list -> thm list -> thm list -> thm list ->
    21     thm list -> thm list -> thm -> int -> int -> thm list list list -> tactic
    22     thm list -> thm list -> thm -> int -> int -> thm list list list -> tactic
    22 end;
    23 end;
    50 
    51 
    51 val exhaust_inst_as_projs_tac = PRIMITIVE oo exhaust_inst_as_projs;
    52 val exhaust_inst_as_projs_tac = PRIMITIVE oo exhaust_inst_as_projs;
    52 
    53 
    53 fun distinct_in_prems_tac distincts =
    54 fun distinct_in_prems_tac distincts =
    54   eresolve_tac (map (fn thm => thm RS neq_eq_eq_contradict) distincts) THEN' atac;
    55   eresolve_tac (map (fn thm => thm RS neq_eq_eq_contradict) distincts) THEN' atac;
       
    56 
       
    57 fun mk_primcorec_nchotomy_tac ctxt disc_exhausts =
       
    58   HEADGOAL (clean_blast_tac ctxt);
    55 
    59 
    56 fun mk_primcorec_exhaust_tac ctxt frees n nchotomy =
    60 fun mk_primcorec_exhaust_tac ctxt frees n nchotomy =
    57   let val ks = 1 upto n in
    61   let val ks = 1 upto n in
    58     HEADGOAL (atac ORELSE'
    62     HEADGOAL (atac ORELSE'
    59       cut_tac nchotomy THEN'
    63       cut_tac nchotomy THEN'