home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Monster Media 1994 #1
/
monster.zip
/
monster
/
PROG_GEN
/
EDSV4064.ZIP
/
EPP-V1_1.ZIP
/
EPP.HIS
< prev
next >
Wrap
Text File
|
1993-06-26
|
7KB
|
174 lines
============================================================================
EPP V1.1 - E Preprocessor.
Copyright ⌐1993 Barry Wills. All rights reserved.
============================================================================
HISTORY.
~~~~~~~
V0.02a - Released 9 May 93.
~~~~~~
1. Adding code to store file handles in the list and leave files open.
This greatly reduces code size and process time, especially in
processProcSections () which had to reopen files and read through
the declarations.
V0.03a - Released 11 May 93.
~~~~~~
1. Modified procedure getModule () to use a project's main program
file as the starting point (instead of the separate directives
file.) The procedure then recursively descends into module
declarations parsing the global declaration sections from the
procedural sections into separate files. The first file (specified
on the command line) gets all the definitions and declarations, the
second (temporary) file gets all procedures. At the end of the
program the temporary file is appended to the specified output file.
2. Runtime progress is sent to stdout. The final output file is
stripped of all comments (except those within procedure bodies), and
some EPP module information is inserted at strategic locations.
3. Later occurrences of redundant modules are ignored.
4. Superfluous PROC main () procedures are omitted in all but the main
module whose name is supplied as the command-line argument. An E
comment is inserted wherever this occurs.
V0.04a - Released 13 May 93.
~~~~~~
1. Comment stripping did not work in all cases, leaving dangling open-
and close-comments. Decided to copy all comments since I had to
track them anyway.
2. Quoted open- and close-comment symbols were being erroneously
counted. Implemented open- aod close-string and -character
tabulators to fix this. (Could have led to shitloads of misread
literals. Eesh!)
V0.10b - Released 15 May 93.
~~~~~~
1. Removed from alpha status.
V0.11b - Released 21 May 93.
~~~~~~
1. Optimized appendProcsToDefs () for speed. Immense gain in speed
achieved using buffered I/O instead of String I/O.
V0.12b - Released 26 May 93.
~~~~~~
1. EPP did not recognize RAISE as a defs keyword. Consequently, all
modules beginning with a RAISE declaration aborted the process.
2. Removed the offending section that said "I don't know what to do
with *token name*". Now if EPP doesn't recognize a keyword in the
defs section the line will just be written as is.
3. Tweeked procedures getModule () and copyDefs () to check for the
two-character string ';\n' after returning from getModule (). The
sourceLine is trimmed after a return from getModule () because only
a partial line would be processed (say, if we had the line:
PMODULE 'mod1'; PMODULE 'mod2';
the two statements are processed by calls to getModule (). This
would leave a semicolon at the end of the line, which was being
printed alone on a line when the call to getModule () returned.
(!@#$%)
4. Corrected serious oversight in copyProc () and getModule () that
allowed quoted keyword 'PROC' to be erroneously recognized as the
keyword PROC. This surfaced while I was attempting to convert EPP
to use PMODULE statements.
5. Converted EPP to use PMODULES. This actually reduced the size of
the executable since I had some duplication of code.
6. Prettied up comments a little.
V0.13b - Released 30 May 93.
~~~~~~
1. Modified IO routines to speed up process. This thing was just too
sluggish! A significant gain in speed was achieved.
2. Bug found in function copyProc (): when a PMODULE containing only a
one-line PROC was copied in the program locked up because it was too
stupid to quit. After examining the logic, I decided that it would
be too involving to checking the syntax close enough to catch mis-
matched PROC ... ENDPROC like I wanted too. We'll just have to be
careful. Sorry!
3. Added switch to silence EPP progress messages.
4. Added switch to set input buffer size. If you have the RAM, use a
large buffer.
5. Added switch to increase the source line length. This must be >=
the input buffer size since a smaller line length could cause a
keyword to be split. The program is friendly where this is
concerned: it warns you if you transgress and will adjust the
buffer if you agree to it. (I may try to figure this out later if
memory consumption turns out to be a problem.)
V0.14b - Released 08 Jun 93.
~~~~~~
1. Removed the constraints on line length -vs- buffer size. After
close examination and much trying to break it, I decided the
safeguard wasn't necessary. There is now a mimimum of 20-byte
file buffers and source lines, and NO MAXIMUM LIMIT. So if you got
the RAM, use it! :-)
This warning still stands: line length must be large enough to
accommodate the longest line of source. If a line is split, a
keyword or a comment delimiter could be missed, and your source
output may be chewed. :-(
2. Corrected token parser to recognize PROC main(), for all you guys
out there who don't like typing unnecessary spaces. |-) Thanks to
Son Le for finding this one.
V1.0 - Released 14 Jun 93.
~~~~
1. Removed from beta status.
2. Added Turbo mode which simply copies the procs section of a module
instead of parsing it to the end. Massively improved speed.
V1.1 - Released 26 Jun 93.
~~~~
1. Modified: parsing routines, to include the addition of
skipToValidToken(). This major contribution belongs to Son Huu Le,
desperately trying to accommodate his poor, overworked 68000 :-)
Thanks Son Le!
2. Modified: startPos becomes PTR TO CHAR .vs. LONG (now renamed to
simply pos.) This eliminates most of the need to pass the string
pointer sourceLine *and* the current index along with it. Resulted
in slight speed increase.
3. Added the OPT TURBO directive to start TURBO mode within a single
module for the duration of that module.
4. Fixed bug in read() that dropped last line of a module if the line
did not end with a linefeed (ascii 10). No more program crashes due
to this error. :)
5. Replaced calls to write() with Write() for speed.
6. Modified program to process CtrlC(). I avoided this previously
because it crashed my machine when handling recursive
Raise (exception)s. A compromise was needed, so I added a control
variable and a test in the main loop of getModule(), and exited
in a more controlled fashion. Still can't figure out why raising
exceptions is trashing my fileHandles (!@#$)
7. Son Huu Le modified appendProcsToDefs() for speed and cosmetics.
============================================================================