ML_Syntax.make_binding;
authorwenzelm
Sun, 15 Mar 2009 15:59:43 +0100
changeset 30524 92af4e8c54a6
parent 30523 4007ea1ddac2
child 30525 8a5a0aa30e1c
ML_Syntax.make_binding;
src/Pure/Isar/isar_cmd.ML
src/Pure/ML/ml_antiquote.ML
--- a/src/Pure/Isar/isar_cmd.ML	Sun Mar 15 15:59:42 2009 +0100
+++ b/src/Pure/Isar/isar_cmd.ML	Sun Mar 15 15:59:43 2009 +0100
@@ -155,9 +155,7 @@
     val body = SymbolPos.content (SymbolPos.explode (body_txt, body_pos));
     val txt =
       "local\n\
-      \  val name = " ^ ML_Syntax.print_string name ^ ";\n\
-      \  val pos = " ^ ML_Syntax.print_position pos ^ ";\n\
-      \  val binding = Binding.make (name, pos);\n\
+      \  val binding = " ^ ML_Syntax.make_binding (name, pos) ^ ";\n\
       \  val body = " ^ body ^ ";\n\
       \in\n\
       \  val " ^ name ^ " = snd (Context.>>> (Context.map_theory_result (Thm.add_oracle (binding, body))));\n\
--- a/src/Pure/ML/ml_antiquote.ML	Sun Mar 15 15:59:42 2009 +0100
+++ b/src/Pure/ML/ml_antiquote.ML	Sun Mar 15 15:59:43 2009 +0100
@@ -59,9 +59,8 @@
 
 structure P = OuterParse;
 
-val _ = inline "binding" (Scan.lift (P.position Args.name) >> (fn b =>
-  ML_Syntax.atomic ("Binding.make " ^
-    ML_Syntax.print_pair ML_Syntax.print_string ML_Syntax.print_position b)));
+val _ = inline "binding"
+  (Scan.lift (P.position Args.name) >> (fn name => ML_Syntax.atomic (ML_Syntax.make_binding name)));
 
 val _ = value "theory"
   (Scan.lift Args.name >> (fn name => "ThyInfo.get_theory " ^ ML_Syntax.print_string name)