Main Page   Alphabetical List   Compound List   File List   Compound Members   File Members  

lclinit.c File Reference

#include "lclintMacros.nf"
#include "llbasic.h"
#include "gram.h"
#include "lclscan.h"
#include "scanline.h"
#include "lclscanline.h"
#include "lcltokentable.h"
#include "lclsyntable.h"
#include "lslinit.h"
#include "lclinit.h"
#include "shift.h"

Go to the source code of this file.

Defines

#define TRACE(rule)

Functions

void LCLProcessInitFile (void)
void LCLProcessInitFileInit (void)
void LCLProcessInitFileReset (void)
void LCLProcessInitFileCleanup (void)


Define Documentation

#define TRACE( rule )
 

Definition at line 47 of file lclinit.c.


Function Documentation

void LCLProcessInitFile ( void )
 

Definition at line 156 of file lclinit.c.

00157 {
00158   InitLines ();
00159 
00160   InitReduce (INITFILE1);
00161 
00162   if (ltoken_getCode (nextToken) != LEOFTOKEN)
00163     {
00164       LocalUserError (nextToken, "unexpected tokens after end-of-file");
00165     }
00166 }

void LCLProcessInitFileCleanup ( void )
 

Definition at line 1545 of file lclinit.c.

01546 {
01547 }

void LCLProcessInitFileInit ( void )
 

Definition at line 1474 of file lclinit.c.

01475 {
01476   int i;
01477 
01478   LSLGenInit (FALSE);           /* parsing LCLinit, not LSLinit */
01479   
01480   /*
01481   ** Insert the init file keywords into the token table as undefined        
01482   ** SIMPLEIDs.  They are defined as simpleIds since they must be treated 
01483   ** that way if they do not appear as the first token on a line, and       
01484   ** they must be treated that way for the actual LSL parsing. Save the   
01485   ** tokens so can recognize as init file keywords when necessary.          
01486   */
01487 
01488   endCommentCharToken = insertSimpleToken ("endCommentChar");
01489   idCharToken = insertSimpleToken ("idChar");
01490   opCharToken = insertSimpleToken ("opChar");
01491   extensionCharToken = insertSimpleToken ("extensionChar");
01492   singleCharToken = insertSimpleToken ("singleChar");
01493   whiteCharToken = insertSimpleToken ("whiteChar");
01494 
01495   quantifierSymToken = insertSimpleToken ("quantifierSym");
01496   logicalOpToken = insertSimpleToken ("logicalOp");
01497   eqOpToken = insertSimpleToken ("eqOp");
01498   equationSymToken = insertSimpleToken ("equationSym");
01499   eqSepSymToken = insertSimpleToken ("eqSepSym");
01500   selectSymToken = insertSimpleToken ("selectSym");
01501   openSymToken = insertSimpleToken ("openSym");
01502   sepSymToken = insertSimpleToken ("sepSym");
01503   closeSymToken = insertSimpleToken ("closeSym");
01504   simpleIdToken = insertSimpleToken ("simpleId");
01505   mapSymToken = insertSimpleToken ("mapSym");
01506   markerSymToken = insertSimpleToken ("markerSym");
01507   commentSymToken = insertSimpleToken ("commentSym");
01508 
01509   synonymToken = insertSimpleToken ("synonym");
01510 
01511   /*
01512   ** Initialize defineSingleChar array to all FALSE to signal that no       
01513   ** characters have been redefined as singleChar. 
01514   */
01515 
01516   for (i = 0; i <= LASTCHAR; i++)
01517     {
01518       defineSingleChar[i] = FALSE;
01519     }
01520 
01521   /* 
01522   ** Record the current extension character so can redefine back to         
01523   ** singleChar if a new extension character is redefined.                  
01524   */
01525 
01526   currentExtensionChar = (charCode) CHAREXTENDER;
01527   
01528   /* Init file processing needs to have EOL reported. */
01529 
01530   LCLReportEolTokens (TRUE);
01531 
01532   /* Not: context_getBoolName () */
01533 
01534   LCLAddSyn (lsymbol_fromChars ("Bool"),
01535              lsymbol_fromChars ("bool"));
01536 }

void LCLProcessInitFileReset ( void )
 

Definition at line 1539 of file lclinit.c.

01540 {
01541   nextToken = LCLScanNextToken ();        
01542 }


Generated at Fri Nov 3 18:57:59 2000 for LCLint by doxygen1.2.3 written by Dimitri van Heesch, © 1997-2000