tuned pretty_tag;
authorwenzelm
Fri, 25 Sep 1998 12:03:11 +0200
changeset 5559 95e8692fda23
parent 5558 64a8495201d1
child 5560 c17471a9c99c
tuned pretty_tag; tag attribute: append;
src/Pure/attribute.ML
--- a/src/Pure/attribute.ML	Fri Sep 25 12:01:47 1998 +0200
+++ b/src/Pure/attribute.ML	Fri Sep 25 12:03:11 1998 +0200
@@ -75,10 +75,7 @@
 
 (* display tagged theorems *)
 
-fun pretty_tag (name, []) = Pretty.str name
-  | pretty_tag (name, args) = Pretty.block
-      [Pretty.str name, Pretty.list "(" ")" (map Pretty.str args)];
-
+fun pretty_tag (name, args) = Pretty.strs (name :: args);
 val pretty_tags = Pretty.list "[" "]" o map pretty_tag;
 
 fun pretty_tthm (thm, []) = Pretty.quote (Display.pretty_thm thm)
@@ -88,7 +85,7 @@
 
 (* basic attributes *)
 
-fun tag tg (x, (thm, tags)) = (x, (thm, tg ins tags));
+fun tag tg (x, (thm, tags)) = (x, (thm, if tg mem tags then tags else tags @ [tg]));
 fun untag tg (x, (thm, tags)) = (x, (thm, tags \ tg));
 
 val lemma = ("lemma", []);