home *** CD-ROM | disk | FTP | other *** search
- ERRMERGE.COM - A Pre-C(tm)/Lattice C(tm) source code correction aid.
-
- | Version 1.01
-
-
- | usage: errmerge [-h] filename
-
- where: filename is the name of the file containing the error messages
- produced by Lattice or Pre-C.
-
- | -h is an option which allows the processing of #included files
- | (those files which do not have a ".c" or ".C" extension).
-
-
- ERRMERGE will read a file containing Lattice C or Phoenix Pre-C error
- messages (perhaps others, read the assumptions below), and will merge
- the error messages before the referenced lines in your source files.
- | Error messages will be inserted in only those files which have a ".c"
- | or ".C" extension unless the -h command line option is included.
-
- Error messages are inserted as comments, so they will not disturb
- compilation. Error messages take the form:
-
- /* ERR: (compiler/analyzer message here) */
-
- The ERR: is inserted to aid in finding error lines with your text
- editor search function. Error messages are inserted starting at the
- first column so they will stand out in indented source code.
-
- To assist in removing the error messages from your source code after
- repairs have been made, the program ERRKILL has been provided.
- ERRKILL uses a work file and creates a backup (contain the error
- messages) as described for ERRMERGE below.
-
- ERRKILL will search a source file for comments beginning with ERR: as
- described above and remove them.
-
-
- Creating the error file:
-
- The error file may be created by redirecting output from the Lattice
- C compiler or the Pre-C syntax analyzer to a DOS text file. The
- error file should have the same name as the C source file, with the
- extension ".ERR".
-
- For Lattice C, redirection should be accomplished as specified in the
- Lattice C manual, with the redirection operator preceding other
- command line options.
-
- For Phoenix Pre-C, redirection is accomplished by following the Pre-C
- command line with "> filename.err" where filename is the name of the
- source file you are checking. If several source files are analyzed
- at the same time with Pre-C, ERRMERGE will merge the generated error
- messages with the appropriate source files in one operation.
-
-
- Other files and disk space usage:
-
- Before merging error messages into a source file, a backup file will
- be created. The backup file will be an exact copy of the C source
- file, with the extension ".BAK". If a backup file (filename.bak)
- already exists, none will be created.
-
- In addition to the backup file, ERRMERGE uses a temporary work file
- which will grow as large as the original source file plus the error
- text to be merged. The temporary file is deleted automatically
- before ERRMERGE exits.
-
- You must have enough free space to hold the error file, source
- file(s), backup file(s) and the temporary work file.
-
-
- Assumptions:
-
- It is assumed that the error file and source files are in the same
- sub-directory.
-
- In analyzing error messages, some assumptions have been made:
-
- 1) Every line to be considered as an error message (in the error
- file) must contain the word "Error" or "Warning" within the
- first 40 characters of the error message.
-
- 2) Every line should contain a line number, and this number must
- be the first number within the error message (if your source
- file name contains a number, ERRMERGE will not work
- properly). If a line does not contain a line number, it will
- be assigned the line number 1, and will be merged at the
- beginning of the source file. If the error line number is 0,
- it will be converted to 1, and will be inserted at the
- beginning of the source file.
-
- 3) Every line should contain the name of the source file which
- produced the error, and this file name must appear just prior
- to the line number (separating spaces are ok). The source
- file name must contain an extension.
-
- If your compiler or analyzer generates error messages which meet the
- above requirements, it may work properly with ERRMERGE.
-
-
- Credits:
-
- ERRMERGE was written (and is copyrighted) by Leroy Casterline, and is
- distributed as "ShareWare". If you find this program useful, please
- consider a contribution ($10 suggested). Source code will be
- provided (if requested and a self-addressed mailer with diskette and
- postage is sent with your contribution).
-
- Please send suggestions, bug reports and contributions to:
-
- Leroy Casterline
-
- Casterline Computer Consulting
- 2507 West Laurel Street
- Fort Collins, Colorado 80521
-
- (303) 223-3490/484-9858
-
-