equal
deleted
inserted
replaced
980 (supp c, |
980 (supp c, |
981 if null dts then HOLogic.mk_set atomT [] |
981 if null dts then HOLogic.mk_set atomT [] |
982 else foldr1 (HOLogic.mk_binop @{const_abbrev union}) (map supp args2))))) |
982 else foldr1 (HOLogic.mk_binop @{const_abbrev union}) (map supp args2))))) |
983 (fn _ => |
983 (fn _ => |
984 simp_tac (HOL_basic_ss addsimps (supp_def :: |
984 simp_tac (HOL_basic_ss addsimps (supp_def :: |
985 Un_assoc :: de_Morgan_conj :: Collect_disj_eq :: finite_Un :: |
985 Un_assoc :: @{thm de_Morgan_conj} :: Collect_disj_eq :: finite_Un :: |
986 Collect_False_empty :: finite_emptyI :: @{thms simp_thms} @ |
986 Collect_False_empty :: finite_emptyI :: @{thms simp_thms} @ |
987 abs_perm @ abs_fresh @ inject_thms' @ perm_thms')) 1) |
987 abs_perm @ abs_fresh @ inject_thms' @ perm_thms')) 1) |
988 in |
988 in |
989 (supp_thm, |
989 (supp_thm, |
990 Goal.prove_global thy8 [] [] (augment_sort thy8 pt_cp_sort |
990 Goal.prove_global thy8 [] [] (augment_sort thy8 pt_cp_sort |
1966 in |
1966 in |
1967 resolve_tac final' 1 |
1967 resolve_tac final' 1 |
1968 end) context 1])) idxss) (ndescr ~~ rec_elims)) |
1968 end) context 1])) idxss) (ndescr ~~ rec_elims)) |
1969 end)); |
1969 end)); |
1970 |
1970 |
1971 val rec_total_thms = map (fn r => r RS theI') rec_unique_thms; |
1971 val rec_total_thms = map (fn r => r RS @{thm theI'}) rec_unique_thms; |
1972 |
1972 |
1973 (* define primrec combinators *) |
1973 (* define primrec combinators *) |
1974 |
1974 |
1975 val big_reccomb_name = space_implode "_" new_type_names ^ "_rec"; |
1975 val big_reccomb_name = space_implode "_" new_type_names ^ "_rec"; |
1976 val reccomb_names = map (Sign.full_bname thy11) |
1976 val reccomb_names = map (Sign.full_bname thy11) |
2009 Goal.prove_global thy12 [] |
2009 Goal.prove_global thy12 [] |
2010 (map (augment_sort thy12 fs_cp_sort) prems') |
2010 (map (augment_sort thy12 fs_cp_sort) prems') |
2011 (augment_sort thy12 fs_cp_sort concl') |
2011 (augment_sort thy12 fs_cp_sort concl') |
2012 (fn {prems, ...} => EVERY |
2012 (fn {prems, ...} => EVERY |
2013 [rewrite_goals_tac reccomb_defs, |
2013 [rewrite_goals_tac reccomb_defs, |
2014 rtac the1_equality 1, |
2014 rtac @{thm the1_equality} 1, |
2015 solve rec_unique_thms prems 1, |
2015 solve rec_unique_thms prems 1, |
2016 resolve_tac rec_intrs 1, |
2016 resolve_tac rec_intrs 1, |
2017 REPEAT (solve (prems @ rec_total_thms) prems 1)]) |
2017 REPEAT (solve (prems @ rec_total_thms) prems 1)]) |
2018 end) (rec_eq_prems ~~ |
2018 end) (rec_eq_prems ~~ |
2019 Datatype_Prop.make_primrecs reccomb_names descr' thy12); |
2019 Datatype_Prop.make_primrecs reccomb_names descr' thy12); |