Equations that are added to the simpset now have proper names.
authorberghofe
Thu, 10 Aug 2000 14:55:21 +0200
changeset 9575 af71f5f4ca6b
parent 9574 da0a964aa601
child 9576 3df14e0a3a51
Equations that are added to the simpset now have proper names.
src/HOL/Tools/primrec_package.ML
--- a/src/HOL/Tools/primrec_package.ML	Thu Aug 10 11:39:53 2000 +0200
+++ b/src/HOL/Tools/primrec_package.ML	Thu Aug 10 14:55:21 2000 +0200
@@ -303,14 +303,14 @@
     val _ = message ("Proving equations for primrec function(s) " ^ commas_quote names1 ^ " ...");
     val simps = map (fn (_, t) => prove_goalw_cterm rewrites (cterm_of (Theory.sign_of thy') t)
         (fn _ => [rtac refl 1])) eqns;
-    val (thy'', [simps']) = thy'
-      |> PureThy.add_thmss [(("simps", simps), [Simplifier.simp_add_global])]
-      |>> (#1 o PureThy.add_thms ((map fst eqns ~~ simps) ~~ atts))
-      |>> (#1 o PureThy.add_thms [(("induct", prepare_induct (#2 (hd dts)) rec_eqns), [])])
-      |>> Theory.parent_path
+    val (thy'', simps') = PureThy.add_thms ((map fst eqns ~~ simps) ~~ atts) thy';
+    val thy''' = thy''
+      |> (#1 o PureThy.add_thmss [(("simps", simps'), [Simplifier.simp_add_global])])
+      |> (#1 o PureThy.add_thms [(("induct", prepare_induct (#2 (hd dts)) rec_eqns), [])])
+      |> Theory.parent_path
   in
     (foldl (fn (thy, (fname, _, _, tname)) =>
-       put_primrec fname (tname, simps') thy) (thy'', defs), simps')
+       put_primrec fname (tname, simps') thy) (thy''', defs), simps')
   end;