changed syntax for axclass attach
authorhaftmann
Fri, 29 Dec 2006 20:34:17 +0100
changeset 21951 56abe5f3c612
parent 21950 e97fd6480091
child 21952 dc9366853df1
changed syntax for axclass attach
src/HOL/Code_Generator.thy
src/Pure/Isar/isar_syn.ML
--- a/src/HOL/Code_Generator.thy	Fri Dec 29 19:50:52 2006 +0100
+++ b/src/HOL/Code_Generator.thy	Fri Dec 29 20:34:17 2006 +0100
@@ -83,7 +83,7 @@
 text {* operational equality for code generation *}
 
 axclass eq \<subseteq> type
-  attach "op ="
+  (attach "op =")
 
 
 text {* equality for Haskell *}
--- a/src/Pure/Isar/isar_syn.ML	Fri Dec 29 19:50:52 2006 +0100
+++ b/src/Pure/Isar/isar_syn.ML	Fri Dec 29 20:34:17 2006 +0100
@@ -88,7 +88,7 @@
   OuterSyntax.command "axclass" "define axiomatic type class" K.thy_decl
     (P.name -- Scan.optional ((P.$$$ "\\<subseteq>" || P.$$$ "<") |--
         P.!!! (P.list1 P.xname)) []
-        -- Scan.optional (P.$$$ "attach" |-- Scan.repeat P.term) []
+        -- Scan.optional (P.$$$ "(" |-- P.$$$ "attach" |-- Scan.repeat P.term --| P.$$$ ")") []
         -- Scan.repeat (P.thm_name ":" -- (P.prop >> single))
       >> (fn ((x, y), z) => Toplevel.theory (snd o AxClass.define_class x y z)));