src/Pure/Isar/parse_spec.ML
changeset 63285 e9c777bfd78c
parent 63183 4d04e14d7ab8
child 63352 4eaf35781b23
equal deleted inserted replaced
63284:c20946f5b6fb 63285:e9c777bfd78c
    65     ((opt_thm_name ":" -- Parse.prop -- if_assumes -- Parse.for_fixes >> Scan.triple1) --|
    65     ((opt_thm_name ":" -- Parse.prop -- if_assumes -- Parse.for_fixes >> Scan.triple1) --|
    66       Scan.option (Scan.ahead (Parse.name || Parse.$$$ "[") -- Parse.!!! (Parse.$$$ "|")));
    66       Scan.option (Scan.ahead (Parse.name || Parse.$$$ "[") -- Parse.!!! (Parse.$$$ "|")));
    67 
    67 
    68 val where_multi_specs = Parse.where_ |-- Parse.!!! multi_specs;
    68 val where_multi_specs = Parse.where_ |-- Parse.!!! multi_specs;
    69 
    69 
    70 val specification = Parse.fixes -- where_multi_specs;
    70 val specification = Parse.vars -- where_multi_specs;
    71 
    71 
    72 
    72 
    73 (* basic constant specifications *)
    73 (* basic constant specifications *)
    74 
    74 
    75 val constdecl =
    75 val constdecl =
   155   Parse.$$$ "when" |-- Parse.!!! statement >> pair false ||
   155   Parse.$$$ "when" |-- Parse.!!! statement >> pair false ||
   156   Scan.succeed (true, []);
   156   Scan.succeed (true, []);
   157 
   157 
   158 val obtain_case =
   158 val obtain_case =
   159   Parse.parbinding --
   159   Parse.parbinding --
   160     (Scan.optional (Parse.and_list1 Parse.fixes --| Parse.where_ >> flat) [] --
   160     (Scan.optional (Parse.and_list1 Parse.vars --| Parse.where_ >> flat) [] --
   161       (Parse.and_list1 (Scan.repeat1 Parse.prop) >> flat));
   161       (Parse.and_list1 (Scan.repeat1 Parse.prop) >> flat));
   162 
   162 
   163 val obtains = Parse.enum1 "|" obtain_case;
   163 val obtains = Parse.enum1 "|" obtain_case;
   164 
   164 
   165 val long_statement =
   165 val long_statement =