-- file Log.mesa
-- last modified by Satterthwaite, September 13, 1982 11:25 am
-- last modified by Sweet, January 16, 1981  12:07 PM
-- last modified by Donahue, 12-Nov-81 15:32:43

DIRECTORY
  Strings: TYPE USING [SubString],
  Symbols: TYPE USING [HTIndex, ISEIndex],
  Tree: TYPE USING [Index, Link];

Log: DEFINITIONS = {

  ErrorCode: TYPE = {
    
   -- general purpose errors (no parameters)
    compilerError,
    unimplemented,
    other,
    aborted,

   -- errors with no parameters
    bodyEntries,
    bodyType,
    catchLabel,
    descriptor,
    discrimForm,
    exit,
    exportedVars,
    fieldSize,
    illDefinedReturn,
    implicitCall,
    inlineType,
    instLength,
    interfaceEntries,
    keys,
    long,
    machDep,
    misplacedCatch,
    misplacedEntry,
    misplacedMonitorRef,
    misplacedResume,
    misplacedReturn,
    misplacedStop,
    misplacedType,
    mixedPositions,
    noAccess,
    nonOrderedType,
    nonTypeCons,
    nonVoidStmt,
    relative,
    staticNesting,
    stringLength,
    subrangeBounds,
    subrangeNesting,
    unreachable,
    unsafeBlock,
    var,
    
   -- errors mapping hash to sei parameters
    unknownId,
    unknownField,

   -- errors with hash parameters
    ambiguousId,
    duplicateId,
    missingImport,
    unknownTag,
    duplicateTag,
    unknownVariant,
    unknownKey,
    duplicateKey,
    omittedKey,
    openId,
    fileName,
    fileVersion,
    fileWrong,
    moduleId,

   -- errors with sei parameters
    addressOverflow,
    circularType,
    circularValue,
    elision,
    enumOrder,
    exportAttr,
    fieldPosition,
    forwardRef,
    inlineRhs,
    internalCall,
    missingBase,
    missingInit,
    missingLock,
    nonDefinition,
    nonTagType,
    nonTypeId,
    notImported,
    position,
    recordGap,
    recordOverlap,
    recursiveInline,
    typeLength,
    varExport,
    voided,

   -- errors with tree parameters
    boundsFault,
    controlId,
    defaultForm,
    duplicateLabel,
    exportClash,
    missingBinding,
    missingCoercion,
    misusedInline,
    mixedRepresentation,
    noApplication,
    nonAddressable,
    nonConstant,
    nonLHS,
    nonVariantLabel,
    noTarget,
    notPortable,
    noVariants,
    overflow,
    relationType,
    scopeFault,
    sizeClash,
    spuriousBinding,
    typeClash,
    unknownLabel,
    unsafeOperation,
    unsafeSelection,

   -- errors with numeric parameters
    listShort,
    listLong,

   -- warnings with no parameters
    attrClash,
    pointerInit,
    stateVector,
    unsafeArgs,

   -- warnings with sei parameters
    privateExport,
    uninitialized,
    unusedExport,
    unusedId,
    unusedImport,
    voidExport,

   -- warnings with substring parameters
    replString,
    replId,

   -- warnings with tree parameters
    unsignedCompare
    };


  Error: PROC [ErrorCode];
  ErrorHti: PROC [ErrorCode, Symbols.HTIndex];
  ErrorN: PROC [ErrorCode, INTEGER];
  ErrorNode: PROC [ErrorCode, Tree.Index];
  ErrorSei: PROC [ErrorCode, Symbols.ISEIndex];
  ErrorTree: PROC [ErrorCode, Tree.Link];

  Warning: PROC [ErrorCode];
  WarningNode: PROC [ErrorCode, Tree.Index];
  WarningSei: PROC [ErrorCode, Symbols.ISEIndex];
  WarningSubString: PROC [ErrorCode, Strings.SubString];
  WarningTree: PROC [ErrorCode, Tree.Link];

  }.