src/Pure/Thy/thy_parse.ML
changeset 865 b38c67991122
parent 777 c007eba368b7
child 889 e87c01fd0351
     1.1 --- a/src/Pure/Thy/thy_parse.ML	Wed Jan 18 10:17:55 1995 +0100
     1.2 +++ b/src/Pure/Thy/thy_parse.ML	Wed Jan 18 11:36:04 1995 +0100
     1.3 @@ -212,7 +212,12 @@
     1.4  val infxl = "infixl" $$-- !! nat >> cat "Infixl";
     1.5  val infxr = "infixr" $$-- !! nat >> cat "Infixr";
     1.6  
     1.7 -val binder = "binder" $$-- !! (string -- nat) >> (cat "Binder" o mk_pair);
     1.8 +fun mk_binder ((name, x), y) =
     1.9 +  let val (p1, p2) = if y = "None" then ("0", x) else (x, y);
    1.10 +  in mk_triple (name, p1, p2) end;
    1.11 +
    1.12 +val binder = "binder" $$-- !! (string -- nat -- optional nat "None") 
    1.13 +             >> (cat "Binder" o mk_binder);
    1.14  
    1.15  val opt_pris = optional ("[" $$-- !! (list nat --$$ "]")) [] >> mk_list;
    1.16