home *** CD-ROM | disk | FTP | other *** search
/ Peanuts NeXT Software Archives / Peanuts-2.iso / Unix / developer / cyacc.README < prev    next >
Encoding:
Text File  |  1994-04-17  |  915 b   |  34 lines

  1. Basically, the skeleton.c file was modified to allow the following:
  2.  
  3.     #define YYLEX [self getToken:stream]
  4.     #define YYPARSE - (int)parse:(FILE*)stream
  5.     #define yyerror(_msg) [self warn:_msg];
  6.  
  7. Make sure these defs appear before your grammar. In the pre-grammar code
  8. one also needs to include the "@implementatin Foo", etc.
  9.  
  10. Code following the grammar (ending "%%") now really follows the parse 
  11. imlementation.
  12.  
  13. I use the following make rule:
  14.  
  15. .my.m:
  16.     cyacc -d -o -x .m -b $* $*.my
  17.  
  18. New Options
  19. -----------
  20. x  uses the next argument as the file extensions (default .c)
  21. o  causes PRIVATE to be defined as "static" thus making the tables and such
  22.    local to the module.
  23.  
  24. The real curious can look at the modifications using rcsdiff on suspect
  25. files. (skeleton.c main.c output.cm defs.h)
  26.  
  27. Sorry about the scant documentation.
  28.  
  29. Please send questions to jjobe@mrj.com.
  30. Will try to get out an example soon.
  31.  
  32. Enjoy,
  33. Jason
  34.