-- TableCompiler.model
-- Copyright (c) 1985 by Xerox Corporation.  All rights reserved.
-- last edit by Satterthwaite, May 30, 1986 12:22:46 pm PDT

LET @///SML/OSBasics.modelBcd!581021414 IN 
LET @///SML/CedarBasics.modelBcd!581021540 IN 
LET @///SML/LoaderBasics.modelBcd!581021616 IN 
LET [
    ConvertUnsafe: TYPE~@/Cedar/Cedar6.1/Rope/ConvertUnsafe.bcd!541570785, 
    IOClasses: TYPE IOClasses~@/Cedar/Cedar6.1/IO/IOClasses.bcd!541577976, 
    ProcessorFace: TYPE~@/Cedar/Cedar6.1/Heads/ProcessorFace.bcd!541571125, 
    RuntimeError: TYPE~@/Cedar/Cedar6.1/MesaRuntime/RuntimeError.bcd!541570482, 
    SymbolTable: TYPE~@/Cedar/Cedar6.1/BcdStuff/SymbolTable.bcd!541573286, 
    UnsafeStorage: TYPE~
      @/Cedar/Cedar6.1/SafeStorage/UnsafeStorage.bcd!541573222] IN 

LAMBDA [
    AsciiImpl: Ascii, 
    BasicTimeImpl: BasicTime, 
    CommanderImpl: Commander, 
    ConvertUnsafeImpl: ConvertUnsafe, 
    FSImpl: FS, 
    IOImpl: IO, 
    IOClassesImpl: IOClasses, 
    LoaderImpl: Loader, 
    PrincOpsUtilsImpl: PrincOpsUtils, 
    ProcessorFaceImpl: ProcessorFace, 
    RopeImpl: Rope, 
    RuntimeErrorImpl: RuntimeError, 
    SymbolTableImpl: SymbolTable, 
    UnsafeStorageImpl: UnsafeStorage, 
    VMImpl: VM] IN 
  
  LET REC [
      
      &options: STRING~"j-b-ns"; 
      --&options: STRING~"j-b-n"; 
      
      -- these come from BasicLoadState.df
      -- Table: TYPE~@Table.mesa!541530693*["s-z"]; 
      -- BcdDefs: TYPE~@BcdDefs.mesa!541530938*["s-z"]; 
      FileSegment: TYPE~@/Cedar/Cedar6.1/BcdStuff/FileSegment.bcd!541573263; 
      
      OSMiscOps: TYPE~@///compiler/OSMiscOps.mesa!563132423*[]; 
      OSMiscOpsImpl: OSMiscOps~@///compiler/OSMiscOpsImpl.mesa!577672349*[]*[]; 
      CommandUtil: TYPE~@///compiler/CommandUtil.mesa!542181810*[]; 
      CommandUtilImpl: CommandUtil~
        @///compiler/CommandPack.mesa!542204761*[]*[]; 
      
      PGSTypes: TYPE~@PGSTypes.mesa!561515273*[]; 
      PGSConDefs: TYPE~@PGSConDefs.mesa!561515530*[]; 
      TableCommand: TYPE~@TableCommand.mesa!543261365*[]; 
      
      StringCompactor: TableCommand~@StringCompactor.mesa!543261956*[]*[]; 
      
      ModuleMaker: TableCommand~
        REC [
          
          BcdImpl: PGSConDefs~
            REC [
              Symbols: TYPE~@/Cedar/Cedar6.1/BcdStuff/Symbols.bcd!541573249; 
              
              SymbolInput: TableCommand~@TableSymbols.mesa!543261856*[]*[]; 
              
              SymbolOutput: PGSConDefs~
                REC [
                  Alloc: TYPE~@///Compiler/InternalAlloc.mesa!561081477*[]; 
                  AllocImpl: Alloc~
                    @///Compiler/InternalAllocImpl.mesa!561081501*[]*[]; 
                  BcdDefs: TYPE~@///Compiler/InternalBcdDefs.mesa!564432582*[]; 
                  Bcd:~@///Compiler/InternalBcdStuff.modelBcd!581022104; 
                  Tree: TYPE~Bcd.Tree*[]; 
                  Literals: TYPE~Bcd.Literals*[]; 
                  Symbols: TYPE~Bcd.Symbols*[]; 
                  SymbolSegment: TYPE~Bcd.SymbolSegment*[]; 
                  SymbolOps: TYPE~Bcd.SymbolOps*[]; 
                  [
                  SymbolPack: TYPE, SymbolPackImpl: SymbolPack, 
                  SymbolOpsBase: SymbolOps]~Bcd.SymbolPack*[]*[]; 
                  SymbolOpsImpl: SymbolOps~
                    SymbolOpsBase + Bcd.SymbolPackExt*[]*[own:~SymbolPackImpl]; 
                  OutputImpl: PGSConDefs~@PGSSymbols.mesa!577404561*[]*[]].OutputImpl; 
              
              Impl: PGSConDefs~
                @PGSBcd.mesa!561661754*[]*[TableCommandImpl:~SymbolInput] 
                  + SymbolOutput].Impl; 
          
          PGSConDefsImpl: PGSConDefs~BcdImpl + ControlImpl; 
          Impl: TableCommand~@ModuleMaker.mesa!543261980*[]*[]].Impl; 
      
      [
      TableCompiler: CONTROL, ControlImpl: PGSConDefs, 
      CommandImpl: TableCommand]~@TableControl.mesa!543261915*[]*[]; 
      
      TableCommandImpl: TableCommand~
        StringCompactor + ModuleMaker + CommandImpl] IN []
