home *** CD-ROM | disk | FTP | other *** search
/ AmigActive 4 / AACD04.ISO / AACD / Programming / envsof20 / source / README < prev   
Encoding:
Text File  |  1999-08-28  |  1.9 KB  |  59 lines

  1. PURPOSE
  2.  
  3.    This directory contains the full source code for the syntax parser
  4.    and the feature scanner.
  5.  
  6.    If you want to recompile them or play around, you need DICE. You
  7.    can download it from Aminet.
  8.  
  9.    Copyright 1999 Thomas Aglassinger and others, see file "forum.txt"
  10.  
  11. SCANNER
  12.  
  13.    The scanner is pretty simple and consists of just one source file.
  14.    This should be straight forward.
  15.  
  16.    However, one important thing to know is the "-ms1" option for DCC
  17.    in the DMakefile. This makes the string constants like "infix" and
  18.    "frozen" end up in the code hunk, so that they are also loaded.
  19.    Otherwise, the whole string comparison stuff with try_skip_word()
  20.    won't work.
  21.  
  22.    Use "dmake" to compile.
  23.  
  24. SYNTAX PARSER
  25.  
  26.    The syntax parser is a lot more complicated. Most of the source
  27.    files are from Dietmar Eilert's examples and have not been touched
  28.    much.
  29.  
  30.    Changed or added files are:
  31.  
  32.       funcs.c - Implements the actual parser.
  33.  
  34.       keyword.c - Functions to read the keyword file into an array.
  35.  
  36.       language.c - A couple of string functions used for detection of
  37.       reserved word and some other syntax elements. Also declares
  38.       several arrays for the various character classes.
  39.  
  40.       tag.a - Declares symbols with the name of parser (_LibName and
  41.       LibId). If these do not match the name in funcs.c, the parser
  42.       won't show up in the configuration window.
  43.  
  44.       lib.c - Library wanking. My only change was to open
  45.       intuition.library to be able to display error messages.
  46.  
  47.    Use "dmake" to compile.
  48.  
  49. TEST PROGRAMS
  50.  
  51.    There are a few files named test_#?.c. I used to compile them with
  52.    SAS/c instead of DICE because of the less unstable debugger. That's
  53.    why there also is a SCOPTIONS in every directory. The test programs
  54.    don't need any register and linker magic and write their results to
  55.    stdout. No need to flush anything afterwards.
  56.  
  57. Thomas.
  58.  
  59.