src/Pure/Syntax/ROOT.ML
changeset 1506 192c48376d25
parent 1078 e57beb974dd7
child 2198 0dddd9575717
equal deleted inserted replaced
1505:14f4c55bbe9a 1506:192c48376d25
    14 use "syn_trans.ML";
    14 use "syn_trans.ML";
    15 use "mixfix.ML";
    15 use "mixfix.ML";
    16 use "printer.ML";
    16 use "printer.ML";
    17 use "syntax.ML";
    17 use "syntax.ML";
    18 
    18 
    19 structure PrivateSyntax =
    19 (*Hiding: only the most basic features are opened*)
    20 struct
    20 structure BasicSyntax: BASIC_SYNTAX = Syntax;
    21   structure Pretty = PrettyFun();
    21 open BasicSyntax;
    22   structure Lexicon = LexiconFun();
       
    23   structure Scanner: SCANNER = Lexicon;
       
    24   structure Ast = AstFun(Pretty);
       
    25   structure SynExt = SynExtFun(structure Lexicon = Lexicon and Ast = Ast);
       
    26   structure Parser = ParserFun(structure Symtab = Symtab and Lexicon = Lexicon
       
    27     and SynExt = SynExt);
       
    28   structure TypeExt = TypeExtFun(structure Lexicon = Lexicon and SynExt = SynExt);
       
    29   structure SynTrans = SynTransFun(structure TypeExt = TypeExt and Parser = Parser);
       
    30   structure Mixfix = MixfixFun(structure Lexicon = Lexicon and SynExt = SynExt and
       
    31     SynTrans = SynTrans);
       
    32   structure Printer = PrinterFun(structure Symtab = Symtab and TypeExt = TypeExt
       
    33     and SynTrans = SynTrans);
       
    34   structure Syntax = SyntaxFun(structure Symtab = Symtab and TypeExt = TypeExt
       
    35     and SynTrans = SynTrans and Mixfix = Mixfix and Printer = Printer);
       
    36   structure BasicSyntax: BASIC_SYNTAX = Syntax;
       
    37 end;
       
    38 
    22 
    39 structure Pretty = PrivateSyntax.Pretty;
    23 structure Scanner: SCANNER = Lexicon;
    40 structure Scanner = PrivateSyntax.Scanner;
       
    41 structure Syntax = PrivateSyntax.Syntax;
       
    42 structure BasicSyntax = PrivateSyntax.BasicSyntax;
       
    43 
       
    44 (* hide functors; saves space in PolyML *)
       
    45 functor PrettyFun() = struct end;
       
    46 functor LexiconFun() = struct end;
       
    47 functor AstFun() = struct end;
       
    48 functor SynExtFun() = struct end;
       
    49 functor ParserFun() = struct end;
       
    50 functor TypeExtFun() = struct end;
       
    51 functor SynTransFun() = struct end;
       
    52 functor MixfixFun() = struct end;
       
    53 functor PrinterFun() = struct end;
       
    54 functor SyntaxFun() = struct end;