src/Pure/Thy/thy_parse.ML
changeset 4496 16187138463d
parent 4362 e10acc395f0d
child 4707 abe6f28a38c1
equal deleted inserted replaced
4495:8648ba842d14 4496:16187138463d
   434   lexicon * (token list -> (string * string) * token list) Symtab.table;
   434   lexicon * (token list -> (string * string) * token list) Symtab.table;
   435 
   435 
   436 fun make_syntax keywords sects =
   436 fun make_syntax keywords sects =
   437   let
   437   let
   438     val dups = duplicates (map fst sects);
   438     val dups = duplicates (map fst sects);
   439     val sects' = distinct_fst_string sects;
   439     val sects' = gen_distinct eq_fst sects;
   440   in
   440   in
   441     if null dups then ()
   441     if null dups then ()
   442     else warning ("Duplicate declaration of theory file sections:\n" ^ commas_quote dups);
   442     else warning ("Duplicate declaration of theory file sections:\n" ^ commas_quote dups);
   443     (make_lexicon (map fst sects' @ keywords), Symtab.make sects')
   443     (make_lexicon (map fst sects' @ keywords), Symtab.make sects')
   444   end;
   444   end;