Annotation of researchv10no/cmd/spitbol/makems.spt, revision 1.1

1.1     ! root        1: -IN80
        !             2: -TITLE MAKEMSG - PRODUCE SPITMSG.MSG FOR VAX/VMS SPITBOL SYSTEM
        !             3: -STITL PREAMBLE
        !             4: *      This is a Macro Spitbol program which generates the
        !             5: *      error message module (SPITMSG.MSG) for the VAX/VMS Spitbol
        !             6: *      interpreter.
        !             7: *
        !             8: *      Inputs to this program are:
        !             9: *
        !            10: *      1. filename.ERR - The list of error numbers and associated
        !            11: *              text from the Minimal translation.  Each record
        !            12: *              in this file consists of a three digit error message
        !            13: *              number and the remainder of the record contains the
        !            14: *              text of the message.  This file need not be sorted.
        !            15: *              It is produced automatically by the XFER program.
        !            16: *      2. Standard INPUT channel - The 'template' for SPITMSG.MSG
        !            17: *              is read using INPUT, and so must immediately follow
        !            18: *              the END statement of the program.  This template is
        !            19: *              copied to SPITMSG.MSG intact, except that lines beginning
        !            20: *              with "[[[" followed by a command are used to signal
        !            21: *              this program to invoke some special action to substitute
        !            22: *              something at that point. (E.g. Error messages).  The
        !            23: *              appendages in this program which perform these special
        !            24: *              actions all begin with "REP_" followed by the command
        !            25: *              used in the template to invoke them.
        !            26: *
        !            27: *      This program creates filename.MSG automatically.
        !            28: *
        !            29: *      Steve Duff for VAX/VMS Spitbol Project April 1980.
        !            30: *
        !            31: -STITL INITIALIZATION
        !            32: *
        !            33: *      Set Keywords
        !            34: *
        !            35:        &STLIMIT = 1000000; &TRIM = 1; &ANCHOR = 1
        !            36: *
        !            37: *      Create File Bindings
        !            38: *
        !            39:        TERMINAL = 'Enter name of .ERR file (no extension).'
        !            40:        TERMINAL = '    Output will be file.MSG.'
        !            41:        FILENAME = TERMINAL
        !            42:        INPUT(.INMESS,1,FILENAME '.ERR')                :F(NOFILE)
        !            43:        OUTPUT(.MSG,2,FILENAME '.MSG')
        !            44: *
        !            45: *      Create the Error Message Array
        !            46: *
        !            47:        MESSARY = ARRAY(899)
        !            48: -STITL PROCESS THE ERROR MESSAGE FILE
        !            49: *
        !            50: *      This initial piece of code reads the input error message file
        !            51: *      into the array MESSARY, indexing each message by its number.
        !            52: *
        !            53: READ_MSGS
        !            54:        MESS    = INMESS                        :F(MAKE_MSG)
        !            55:        MESS    LEN(3) . MESSID  REM . MESSTEXT :F(FORMATBAD)
        !            56:        MAX_MESSID = GT(MESSID,MAX_MESSID) MESSID
        !            57:        MESSARY[MESSID] = MESSTEXT              :(READ_MSGS)
        !            58: -SPACE 3
        !            59: *
        !            60: *      Now we generate SPITMSG.MSG using the template.
        !            61: *
        !            62: MAKE_MSG
        !            63:        EMLINE  = INPUT                         :F(EXIT)
        !            64:        EMLINE  '[[['  REM . CMD                :S($('REP_' CMD))
        !            65:        MSG     = EMLINE                        :(MAKE_MSG)
        !            66: -SPACE 3
        !            67: *
        !            68: *      Here when finished
        !            69: *
        !            70: EXIT   :(END)
        !            71: -STITL SUBSTITUTION APPENDAGES
        !            72: *
        !            73: *      Substitute error messages
        !            74: *
        !            75: REP_DOERRS
        !            76:        MESSID  = 0
        !            77: RDE.LOOP
        !            78:        MESSID  = LT(MESSID,MAX_MESSID) MESSID + 1      :F(MAKE_MSG)
        !            79:        MSG     = ' ERR' LPAD(MESSID,3,0) ' <' MESSARY[MESSID] '>/WARNING'
        !            80:        :(RDE.LOOP)
        !            81: *
        !            82: *      Emit definition for maximum error message number
        !            83: *
        !            84: REP_MAXMSG
        !            85:        MSG     = '     .LITERAL SPITBOL_MAXMSG = ' MAX_MESSID  :(MAKE_MSG)
        !            86: END
        !            87:  .TITLE        SPITMSG - MACRO SPITBOL Error Message Definitions
        !            88:  .FACILITY     SPITBOL,1000
        !            89:  .SEVERITY     SEVERE
        !            90:  EXIT          <EXIT Module Saved - !AD>/INFORMATIONAL/FAO=2
        !            91:  EXSUP         <Execution Suppressed>/INFORMATIONAL
        !            92:  INSVIRMEM     <Insufficient Virtual Memory>
        !            93:  LINETRUNC     <Input Source Line Truncated>/WARNING
        !            94:  LOADCRC       <Load Incompatible, Please Retranslate Source>
        !            95:  LOADMEM       <Insufficient Virtual Memory For LOAD>
        !            96:  LOADOPEN      <Can't Open LOAD File - !AD>/FAO=2
        !            97:  LOADMAP       <Error Mapping LOAD File - !AD>/FAO=2
        !            98:  LOADUNEXCOND  <Loaded Function Failed To Handle Condition At PC=!XL>/FAO=1/ERROR
        !            99:  LOADUNEXTRY   <Will Attempt to Recover By Forcing Failure>/WARN
        !           100:  LOADVERS      <Load Versions Incompatible, Please Retranslate Source>
        !           101:  NOSYSOUT      <Output File Not Accessable>
        !           102:  NOTEXITMOD    <File is Not a Saved EXIT File - !AD>/FAO=2
        !           103:  OPENOUT       <Error Opening !AD as Output>/FAO=2
        !           104:  OPENIN                <Error Opening !AD as Input>/FAO=2
        !           105:  PAUSE         <Paused at Statement !ZL>/FAO=1/INFORMATIONAL
        !           106:  STACKOVFL     <Virtual Stack Space Exhausted>
        !           107:  SYNTAX                <Syntax Error In Command Line>
        !           108: !
        !           109: ! New in V3.5(BCAB-1131)
        !           110: !
        !           111:  BADLINK       <Incorrectly specified BASE(s) in SPITBOL link>
        !           112:  LOADBADINT    <Loaded function returned invalid integer result pointer>/WARN
        !           113:  LOADBADREAL   <Loaded function returned invalid real number result ptr>/WARN
        !           114:  LOADBADSTRING <Loaded function returned invalid string descriptor>/WARN
        !           115:  LOADBADUNCONV <Loaded function returned bad block for unconverted result>/WARN
        !           116:        .PAGE
        !           117:  ERR000 <Internal Spitbol System Error - Please Submit SPR>/SEVERE
        !           118: [[[DOERRS
        !           119: [[[MAXMSG
        !           120:        .END

unix.superglobalmegacorp.com

This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.