-- Error.mesa
--    Last edited by Lewis on October 20, 1980  12:01 PM
--    Last edited by Sweet on July 9, 1980  3:20 PM

DIRECTORY
  BcdDefs USING [FTIndex, MTIndex, NameRecord, VersionStamp],
  SourceBcd USING [ComponentKind, CTreeIndex],
  Strings USING [SubString],
  SymTabDefs USING [HTIndex];

Error: DEFINITIONS =
  BEGIN

  ErrorClass: TYPE = {error, warning};

  Error: PROC [class: ErrorClass, s: STRING];
  ErrorHti: PROC [class: ErrorClass, s: STRING, hti: SymTabDefs.HTIndex];
  ErrorFile: PROC [class: ErrorClass, s: STRING, fti: BcdDefs.FTIndex];
  ErrorName: PROC [class: ErrorClass, s: STRING, name: BcdDefs.NameRecord];

  WrongSymbolsVersion: PROC [
    class: ErrorClass, 
    module: BcdDefs.MTIndex, 
    requiredVersion, actualVersion: BcdDefs.VersionStamp];

  UnknownComponent: PROC [
    class: ErrorClass, 
    kind: SourceBcd.ComponentKind, 
    mainPartOfCompId: SymTabDefs.HTIndex];

  AmbiguousComponent: PROC [
    class: ErrorClass, 
    kind: SourceBcd.ComponentKind, 
    compNode1, compNode2: SourceBcd.CTreeIndex];

  -- One of the code packs excepted by an implicit component description has 
  -- itself an implicit c.d. including a module of the original c.d. (whew)   
  ImplicitCDIncludesModule: PROC [
    class: ErrorClass, 
    componentId, codePackId: SymTabDefs.HTIndex, 
    module: BcdDefs.MTIndex];

  ModuleInTwoSegments: PROC [
    class: ErrorClass, 
    module: BcdDefs.MTIndex, 
    segId1, segId2: SymTabDefs.HTIndex];

  ModuleAlreadyPacked: PROC [
    class: ErrorClass, 
    module: BcdDefs.MTIndex];

  TableCompModuleNotIncAsUnit: PROC [
    class: ErrorClass, 
    module: BcdDefs.MTIndex];

  NotProcInModule: PROC [
    class: ErrorClass, 
    procName: SymTabDefs.HTIndex, 
    module: BcdDefs.MTIndex];

  ProcPlacedTwice: PROC [
    class: ErrorClass, 
    procId: Strings.SubString, 
    module: BcdDefs.MTIndex,
    cpId1, cpId2: SymTabDefs.HTIndex];

  ProcNotPlaced: PROC [
    class: ErrorClass, 
    procId: Strings.SubString, 
    module: BcdDefs.MTIndex];

  NoProcFromModuleInCP: PROC [
    class: ErrorClass, 
    module: BcdDefs.MTIndex, 
    cpId: SymTabDefs.HTIndex];

  FrameInTwoFramePacks: PROC [
    class: ErrorClass, 
    module: BcdDefs.MTIndex, 
    fpId1, fpId2: SymTabDefs.HTIndex];

  FrameNotPlaced: PROC [
    class: ErrorClass, 
    module: BcdDefs.MTIndex];

  SegmentTooLarge: PROC [
    class: ErrorClass, 
    segId: Strings.SubString];

  END.