src/ZF/Tools/primrec_package.ML
changeset 54742 7a86358a3c0b
parent 51930 52fd62618631
child 58011 bc6bced136e5
equal deleted inserted replaced
54741:010eefa0a4f3 54742:7a86358a3c0b
   174 
   174 
   175     val rewrites = def_thm :: map mk_meta_eq (#rec_rewrites con_info)
   175     val rewrites = def_thm :: map mk_meta_eq (#rec_rewrites con_info)
   176     val eqn_thms =
   176     val eqn_thms =
   177       eqn_terms |> map (fn t =>
   177       eqn_terms |> map (fn t =>
   178         Goal.prove_global thy1 [] [] (Ind_Syntax.traceIt "next primrec equation = " thy1 t)
   178         Goal.prove_global thy1 [] [] (Ind_Syntax.traceIt "next primrec equation = " thy1 t)
   179           (fn _ => EVERY [rewrite_goals_tac rewrites, rtac @{thm refl} 1]));
   179           (fn {context = ctxt, ...} => EVERY [rewrite_goals_tac ctxt rewrites, rtac @{thm refl} 1]));
   180 
   180 
   181     val (eqn_thms', thy2) =
   181     val (eqn_thms', thy2) =
   182       thy1
   182       thy1
   183       |> Global_Theory.add_thms ((eqn_names ~~ eqn_thms) ~~ eqn_atts);
   183       |> Global_Theory.add_thms ((eqn_names ~~ eqn_thms) ~~ eqn_atts);
   184     val (_, thy3) =
   184     val (_, thy3) =