Isar setups;
authorwenzelm
Mon, 09 Nov 1998 15:41:24 +0100
changeset 5839 3ad1364bbb4b
parent 5838 a4122945d638
child 5840 e2d2b896c717
Isar setups;
src/Pure/pure.ML
--- a/src/Pure/pure.ML	Mon Nov 09 15:40:26 1998 +0100
+++ b/src/Pure/pure.ML	Mon Nov 09 15:41:24 1998 +0100
@@ -5,22 +5,32 @@
 Setup the actual Pure and CPure theories.
 *)
 
-structure Pure =
-struct
-  val thy =
-    PureThy.begin_theory "Pure" [ProtoPure.thy]
-    |> Theory.add_syntax Syntax.pure_appl_syntax
-    |> Theory.apply Locale.setup
-    |> PureThy.end_theory;
-end;
+local
+  val common_setup =
+    ObjectLogic.setup @
+    Locale.setup @
+    ProofContext.setup @
+    Method.setup @
+    Attrib.setup;
+in
+  structure Pure =
+  struct
+    val thy =
+      PureThy.begin_theory "Pure" [ProtoPure.thy]
+      |> Theory.add_syntax Syntax.pure_appl_syntax
+      |> Theory.apply common_setup
+      |> PureThy.end_theory;
+  end;
 
-structure CPure =
-struct
-  val thy =
-    PureThy.begin_theory "CPure" [ProtoPure.thy]
-    |> Theory.add_syntax Syntax.pure_applC_syntax
-    |> Theory.apply Locale.setup
-    |> PureThy.end_theory;
+  structure CPure =
+  struct
+    val thy =
+      PureThy.begin_theory "CPure" [ProtoPure.thy]
+      |> Theory.add_syntax Syntax.pure_applC_syntax
+      |> Theory.apply common_setup
+      |> Theory.prep_ext                  (*copy shared data!*)
+      |> PureThy.end_theory;
+  end;
 end;
 
 ThyInfo.loaded_thys :=