main.c revision 4fd606d1f5abe38e1f42c38de1d2e895166bd0f4
/*
* main.c -- main program for PCCTS ANTLR.
*
* SOFTWARE RIGHTS
*
* We reserve no LEGAL rights to the Purdue Compiler Construction Tool
* Set (PCCTS) -- PCCTS is in the public domain. An individual or
* company may do whatever they wish with source code distributed with
* PCCTS or the code generated by PCCTS, including the incorporation of
* PCCTS, or its output, into commerical software.
*
* We encourage users to develop software with PCCTS. However, we do ask
* that credit is given to us for developing PCCTS. By "credit",
* we mean that if you incorporate our source code into one of your
* programs (commercial product, research project, or otherwise) that you
* acknowledge this fact somewhere in the documentation, research report,
* etc... If you like PCCTS and have developed a nice tool with the
* output, please mention that you developed it using PCCTS. In
* addition, we ask that this header remain intact in our source code.
* As long as these guidelines are kept, we expect to continue enhancing
* this system and expect to make other tools available as they are
* completed.
*
* ANTLR 1.33
* Terence Parr
* Parr Research Corporation
* with Purdue University and AHPCRC, University of Minnesota
* 1989-2001
*/
/* To set a breakpoint just before exit look for "cleanUp". */
/* To set a breakpoint for fatal error look for "fatal_intern" */
#include <stdio.h>
#include "pcctscfg.h"
#include "stdpccts.h"
#define MAX_INT_STACK 50
static int isp = MAX_INT_STACK;
static int DontAcceptFiles = 0; /* if stdin, don't read files */
static int DontAcceptStdin = 0; /* if files seen first, don't accept stdin */
static int tnodes_used_in_guard_predicates_etc; /* MR10 */
/* C m d - L i n e O p t i o n S t r u c t & F u n c s */
typedef struct _Opt {
char *option;
int arg;
#ifdef __cplusplus
void (*process)(...);
#else
void (*process)();
#endif
char *descr;
} Opt;
#ifdef __USE_PROTOS
extern void ProcessArgs(int, char **, Opt *);
#else
extern void ProcessArgs();
#endif
#ifdef __USE_PROTOS
int ci_strequ(char *a,char *b)
#else
int ci_strequ(a,b)
char *a;
char *b;
#endif
{
for ( ;*a != 0 && *b != 0; a++, b++) {
}
return (*a == *b);
}
static void
#ifdef __USE_PROTOS
pStdin( void )
#else
pStdin( )
#endif
{
if ( DontAcceptStdin )
{
warnNoFL("'-' (stdin) ignored as files were specified first");
return;
}
DontAcceptFiles = 1;
}
static void
#ifdef __USE_PROTOS
pFile( char *s )
#else
pFile( s )
char *s;
#endif
{
if ( DontAcceptFiles )
{
return;
}
DontAcceptStdin = 1;
}
/* MR14
Allow input to be a file containing a list of files
Bernard Giroud (b_giroud@decus.ch)
*/
static void
#ifdef __USE_PROTOS
pFileList( char *s, char *t )
#else
pFileList( s, t )
char *s;
char *t;
#endif
{
#define MaxFLArea 1024
char one_fn[MaxFileName];
if ( DontAcceptFiles )
{
return;
}
{
return;
}
for (;;)
{
break;
/* drop the trailing LF */
}
DontAcceptStdin = 1;
}
static void
#ifdef __USE_PROTOS
pLLK( char *s, char *t )
#else
pLLK( s, t )
char *s;
char *t;
#endif
{
if ( LL_k <= 0 ) {
warnNoFL("must have at least one token of lookahead (setting to 1)");
LL_k = 1;
}
}
static void
#ifdef __USE_PROTOS
pCk( char *s, char *t )
#else
pCk( s, t )
char *s;
char *t;
#endif
{
if ( CLL_k <= 0 ) {
warnNoFL("must have at least one token of look-ahead (setting to 1)");
CLL_k = 1;
}
}
static void /* MR6 */
#ifdef __USE_PROTOS
pTab( char *s, char *t ) /* MR6 */
#else
pTab( s, t ) /* MR6 */
char *s; /* MR6 */
char *t; /* MR6 */
#endif
{ /* MR6 */
TabWidth=0; /* MR6 */
} /* MR6 */
} /* MR6 */
static int ambAidDepthSpecified=0; /* MR11 */
static void /* MR11 */
#ifdef __USE_PROTOS
pAAd( char *s, char *t ) /* MR11 */
#else
pAAd( s, t ) /* MR11 */
char *s; /* MR11 */
char *t; /* MR11 */
#endif
{ /* MR11 */
} /* MR11 */
static void /* MR11 */
#ifdef __USE_PROTOS
pTreport( char *s, char *t ) /* MR11 */
#else
pTreport( s, t ) /* MR11 */
char *s; /* MR11 */
char *t; /* MR11 */
#endif
{ /* MR11 */
} /* MR11 */
#ifdef __USE_PROTOS
void chkGTFlag(void) /* 7-Apr-97 MR1 */
#else
void chkGTFlag() /* 7-Apr-97 MR1 */
#endif
{
if ( !GenAST )
warn("#-variable or other AST item referenced w/o -gt option");
}
#ifdef __USE_PROTOS
static void pInfo(char *s, char *t) /* MR10 */
#else
static void pInfo(s,t) /* MR10 */
char *s;
char *t;
#endif
{
char *p;
int q;
for (p=t; *p != 0; p++) {
q=tolower(*p);
if (q=='t') {
InfoT=1;
} else if (q=='p') {
InfoP=1;
} else if (q=='m') {
InfoM=1;
} else if (q=='o') {
InfoO=1;
} else if (q=='0') {
; /* nothing */
} else if (q=='f') {
InfoF=1;
} else {
};
};
}
#ifdef __USE_PROTOS
/*static void pCt(void) { warnNoFL("-ct option is now the default"); }*/
static void pFr(char *s, char *t) {RemapFileName = t;}
static void pFe(char *s, char *t) {ErrFileName = t;}
static void pFl(char *s, char *t) {DlgFileName = t;}
static void pFm(char *s, char *t) {ModeFileName = t;}
static void pFt(char *s, char *t) {DefFileName = t;}
static void pDL(void)
{
DemandLookahead = 1;
if ( GenCC ) {
warnNoFL("-gk does not work currently in C++ mode; -gk turned off");
DemandLookahead = 0;
}
}
#else
/*static void pCt() { warnNoFL("-ct option is now the default"); }*/
static void pFr(s,t) char *s, *t; {RemapFileName = t;}
static void pFe(s,t) char *s, *t; {ErrFileName = t;}
static void pFl(s,t) char *s, *t; {DlgFileName = t;}
static void pFm(s,t) char *s, *t; {ModeFileName = t;}
static void pFt(s,t) char *s, *t; {DefFileName = t;}
static void pDL()
{
DemandLookahead = 1;
if ( GenCC ) {
warnNoFL("-gk does not work currently in C++ mode; -gk turned off");
DemandLookahead = 0;
}
}
#endif
static void
#ifdef __USE_PROTOS
pPre( char *s, char *t )
#else
pPre( s, t )
char *s;
char *t;
#endif
{
RulePrefix = t;
}
static void
#ifdef __USE_PROTOS
pOut( char *s, char *t )
#else
pOut( s, t )
char *s;
char *t;
#endif
{
OutputDirectory = t;
}
static void
#ifdef __USE_PROTOS
pPred( void )
#else
pPred( )
#endif
{
warnNoFL("-pr is no longer used (predicates employed if present); see -prc, -mrhoist, -mrhoistk");
/*
** if ( DemandLookahead )
** warnNoFL("-gk conflicts with -pr; -gk turned off");
** DemandLookahead = 0;
** HoistPredicateContext = 0;
*/
}
static void
#ifdef __USE_PROTOS
pPredCtx( char *s, char *t )
#else
pPredCtx(s,t)
char *s;
char *t;
#endif
{
if ( DemandLookahead )
{
warnNoFL("-gk incompatible with semantic predicate usage; -gk turned off");
DemandLookahead = 0;
}
}
static void
#ifdef __USE_PROTOS
pMRhoist( char *s, char *t )
#else
pMRhoist(s,t)
char *s;
char *t;
#endif
{
if (MRhoisting) {
fprintf(stderr,"Maintenance Release style hoisting enabled for predicates with lookahead depth = 1\n");
};
}
static void
#ifdef __USE_PROTOS
pMRhoistk( char *s, char *t )
#else
pMRhoistk(s,t)
char *s;
char *t;
#endif
{
if (MRhoistingk) {
};
}
static void
#ifdef __USE_PROTOS
pTRes( char *s, char *t )
#else
pTRes( s, t )
char *s;
char *t;
#endif
{
TreeResourceLimit = atoi(t);
if ( TreeResourceLimit <= 0 )
{
warnNoFL("analysis resource limit (# of tree nodes) must be greater than 0");
}
}
#ifdef __cplusplus
{ "-e3", 0, (void (*)(...)) pE3,
"Ambiguities for k>1 grammars shown with exact tuples (not lookahead sets)"},
{ "-ge", 0, (void (*)(...)) pEGen, "Generate an error class for each non-terminal (default=FALSE)"},
{ "-glms", 0, (void (*)(...)) pLIms,"Like -gl but replace '\\' with '/' in #line filenames for MS C/C++ systems"},
{ "-gs", 0, (void (*)(...)) pSGen, "Do not generate sets for token expression lists (default=FALSE)"},
{ "-pa", 0, (void (*)(...)) pPrtA, "Print out the grammar w/o actions & w/FIRST sets (default=no)"},
{ "-tab", 1, (void (*)(...)) pTab, "Width of tabs (1 to 8) for grammar.c/grammar.cpp files"}, /* MR6 */
{ "-aa" , 1, (void (*)(...)) pAA, "Ambiguity aid for a rule (rule name or line number)"}, /* MR11 */
{ "-aam" , 0, (void (*)(...)) pAAm,
"Lookahead token may appear multiple times in -aa listing"}, /* MR11 */
"Limits exp growth of -aa listing - default=1 (max=ck value)"}, /* MR11 */
"Report when tnode usage exceeds value during ambiguity resolution"}, /* MR11 */
{ "-newAST", 0, (void (*)(...)) pNewAST,
"In C++ mode use \"newAST(...)\" rather than \"new AST(...)\""}, /* MR13 */
{ "-tmake", 0, (void (*)(...)) ptmakeInParser,
"In C++ mode use parser's tmake method rather than \"ASTBase::tmake(...)\""}, /* MR23 */
{ "-alpha",0,(void (*)(...)) pAlpha,
"Provide additional information for \"(alpha)? beta\" error messages"}, /* MR14 */
"EXPERIMENTAL change to (...)* and (...)+ syntax error sets"}, /* MR21 */
{ "-nopurify",0,(void (*)(...)) pNOPURIFY,
"Don't use the notorious PURIFY macro (replaced by MR23 initial value syntax) to zero return arguments of rules"}, /* MR23 */
#else
{ "-aam" ,0,pAAm,
"Lookahead token may appear multiple times in -aa listing"}, /* MR11 */
"Limits exp growth of -aa listing - default=1 (max=ck value)"}, /* MR11 */
"Report when tnode usage exceeds value during ambiguity resolution"}, /* MR11 */
{ "-newAST", 0, pNewAST,
"In C++ mode use \"newAST(...)\" rather than \"new AST(...)\""}, /* MR13 */
{ "-tmake", 0, ptmakeInParser,
"In C++ mode use parser's tmake method rather than \"ASTBase::tmake(...)\""}, /* MR23 */
{ "-alpha",0, pAlpha,
"Provide additional information for \"(alpha)? beta\" error messages"}, /* MR14 */
"EXPERIMENTAL change to (...)* and (...)+ syntax error sets"}, /* MR21 */
{ "-nopurify",0,pNOPURIFY,
"Don't use the notorious PURIFY macro (replaced by MR23 initial value syntax) to zero return arguments of rules"}, /* MR23 */
#endif
};
void readDescr();
void cleanUp();
#ifdef __USE_PROTOS
static void buildRulePtr( void );
static void help( void );
static void init( void );
static void CompleteTokenSetRefs( void );
static void ensure_no_C_file_collisions(char *);
static void CompleteContextGuards(void);
#else
static void buildRulePtr( );
static void help( );
static void init( );
static void CompleteTokenSetRefs( );
static void ensure_no_C_file_collisions();
static void CompleteContextGuards();
#endif
static void
#ifdef __USE_PROTOS /* <BJS> */
#else
ActionNode *a;
#endif
{ /* MR10 */
warnFL("numeric references to attributes (e.g. $i or $i.j) in semantic pred will be null during guess mode", /* MR10 */
} /* MR10 */
/* M a i n */
int
#ifdef __USE_PROTOS
#else
int argc;
char *argv[];
#endif
{
int i;
static char EPSTR[] = "[Ep]";
/* malloc_debug(8);*/
#ifdef SPECIAL_INITS
special_inits(); /* MR1 */
#endif
/* MR14 */ }
if (MRhoistingk) { /* MR13 */
}; /* MR13 */
if (MRhoisting && ! HoistPredicateContext) {
/*** warnNoFL("Using \"-mrhoist\" forces \"-prc on\""); ***/
};
if (HoistPredicateContext && ! MRhoisting) {
warnNoFL("When using predicate context (-prc on) -mrhoist on is recommended");
}
/* Fix lookahead depth */
/* Compressed lookahead must always be larger than or equal to full lookahead */
{
warnNoFL("must have compressed lookahead >= full LL(k) lookahead (setting -ck to -k)");
}
OutputLL_k = CLL_k;
int n;
OutputLL_k = n;
};
if (MR_BlkErr) {
warnNoFL("The -mrblkerr option is EXPERIMENTAL");
if (LL_k > 1) {
warnNoFL("The -mrblkerr option is designed only for k=1 ck=1 grammars");
}
};
if ( ! ambAidDepthSpecified) {
} else {
"Ambiguity aid depth (\"-aad ...\") must be a number between 1 and max(k,ck)=%d",CLL_k));
};
if (MR_AmbAidDepth == 0) {
};
};
init();
readDescr();
warnNoFL("no #header action was found");
if ( FoundAtOperator && ! FoundExceptionGroup) {
warnNoFL("found the exception operator '@' - but no exception group was found");
};
/* this won't work for hand-built scanners since EofToken is not
* known. Forces EOF to be token type 1.
*/
/* compute the set of all known token types
* It represents the set of tokens from 1 to last_token_num + the
* reserved positions above that (if any). Don't include the set of
*/
{
set a;
a = set_dup(reserved_positions);
set_free(a);
}
ComputeTokSets(); /* Compute #tokclass sets */
CompleteTokenSetRefs(); /* Change complex nodes in syn diag */
CompleteContextGuards(); /* MR13 */
if ( GenStdPccts )
{
else
{
#ifdef SPECIAL_FOPEN
#endif
} else { /* MR10 */
};
fclose(f);
}
}
buildRulePtr(); /* create mapping from rule # to RuleBlk junction */
if ( CodeGen )
{
{
warnNoFL("no grammar description recognized");
cleanUp();
}
else if ( !GenCC ) {
#ifdef SPECIAL_FOPEN
#endif
NewSetWd();
GenErrHdr();
DumpSetWd();
}
else {
#ifdef SPECIAL_FOPEN
#endif
#ifdef SPECIAL_FOPEN
#endif
if ( class_before_actions != NULL )
{
ListNode *p;
{
}
}
NewSetWd();
DumpSetWd();
if ( class_after_actions != NULL )
{
ListNode *p;
{
}
}
}
}
if (GenCC) {
warnNoFL("At least one <<action>> following a token match contains a reference to LT(...)\n this will reference the immediately preceding token,\n not the one which follows as is the case with semantic predicates.");
}
warnNoFL("At least one <<action>> following a token match contains a reference to LA(...) or LATEXT(...)\n this will reference the immediately preceding token,\n not the one which follows as is the case with semantic predicates.");
}
if ( PrintOut )
{
}
#ifdef DBG_LL1
#endif
GenRemapFile(); /* create remap.h */
/* MR10 */ if (FoundGuessBlk) {
#ifdef __cplusplus__
#else
#ifdef __USE_PROTOS
#else
#endif
#endif
/* MR10 */ };
if (InfoT && TnodesAllocated > 0) {
if (TnodesPeak > 10000) {
(TnodesPeak/1000),
(TnodesAllocated/1000),
} else {
};
};
if (InfoF) {
DumpFcache();
};
if (MR_skipped_e3_report) {
};
if (MR_BadExprSets != 0) {
};
if (MR_AmbAidLine == 0 && q == NULL) {
} else {
};
};
if (AlphaBetaTrace) {
if (MR_AlphaBetaMessageCount == 0) {
fprintf(stderr,"note: there were no messages about \"(alpha)? beta\" blocks added to the generated code\n");
} else {
fprintf(stderr,"note: there were %d messages about \"(alpha)? beta\" blocks added to the generated code\n",
}
if (set_null(MR_CompromisedRules)) {
} else {
}
}
cleanUp();
return 0; /* MR11 make compilers happy */
}
static void
#ifdef __USE_PROTOS
init( void )
#else
init( )
#endif
{
SignalEntry *q;
Tname = newHashTable();
Rname = newHashTable();
Fcache = newHashTable();
Tcache = newHashTable();
Sname = newHashTable();
/* Add default signal names */
"NoViableAlt",
q->signum = sigNoViableAlt;
"MismatchedToken",
q->signum = sigMismatchedToken;
"NoSemViableAlt",
q->signum = sigNoSemViableAlt;
all_tokens = empty;
imag_tokens = empty;
tokclasses = empty;
}
static void
#ifdef __USE_PROTOS
help( void )
#else
help( )
#endif
{
while ( *(p->option) != '*' )
{
p->option,
p->descr);
p++;
}
}
/* The RulePtr array is filled in here. RulePtr exists primarily
* so that sets of rules can be maintained for the FOLLOW caching
* mechanism found in rJunc(). RulePtr maps a rule num from 1 to n
* to a pointer to its RuleBlk junction where n is the number of rules.
*/
static void
#ifdef __USE_PROTOS
buildRulePtr( void )
#else
buildRulePtr( )
#endif
{
int r=1;
while ( p!=NULL )
{
RulePtr[r++] = p;
}
}
void
#ifdef __USE_PROTOS
dlgerror(const char *s)
#else
dlgerror(s)
char *s;
#endif
{
}
void
#ifdef __USE_PROTOS
readDescr( void )
#else
readDescr( )
#endif
{
}
FILE *
#ifdef __USE_PROTOS
NextFile( void )
#else
NextFile( )
#endif
{
FILE *f;
for (;;)
{
CurFile++;
if ( f == NULL )
{
}
else
{
return(f);
}
}
}
/*
* Return a string corresponding to the output file name associated
* with the input file name passed in.
*
* Observe the following rules:
*
* f.e --> f".c"
* f --> f".c"
* f. --> f".c"
* f.e.g --> f.e".c"
*
* Where f,e,g are arbitrarily long sequences of characters in a file
* name.
*
* In other words, if a ".x" appears on the end of a file name, make it
* ".c". If no ".x" appears, append ".c" to the end of the file name.
*
* C++ mode using .cpp not .c.
*
* Use malloc() for new string.
*/
char *
#ifdef __USE_PROTOS
#else
char *fs;
#endif
{
if ( GenCC) {
} else {
};
}
char *
#ifdef __USE_PROTOS
#else
char *fs;
char *suffix;
#endif
{
char *p;
p = buf;
while ( *p != '\0' ) {p++;} /* Stop on '\0' */
return( buf );
}
void
#ifdef __USE_PROTOS
#else
char *err_;
char *f;
int l;
#endif
{
cleanUp();
}
void
#ifdef __USE_PROTOS
fatal_intern( char *err_, char *f, int l )
#else
fatal_intern( err_, f, l )
char *err_;
char *f;
int l;
#endif
{
cleanUp();
}
void
#ifdef __USE_PROTOS
cleanUp( void )
#else
cleanUp( )
#endif
{
}
/* sprintf up to 3 strings */
char *
#ifdef __USE_PROTOS
#else
char *s;
char *a1;
char *a2;
char *a3;
#endif
{
return( buf );
}
/* sprintf a decimal */
char *
#ifdef __USE_PROTOS
eMsgd( char *s, int d )
#else
eMsgd( s, d )
char *s;
int d;
#endif
{
return( buf );
}
char *
#ifdef __USE_PROTOS
#else
char *s;
int d1;
int d2;
#endif
{
return( buf );
}
void
#ifdef __USE_PROTOS
#else
s_fprT( f, e )
FILE *f;
set e;
#endif
{
register unsigned *p;
unsigned *q;
if ( set_nil(e) ) return;
fprintf(f, "{");
while ( *p != nil )
{
p++;
}
fprintf(f, " }");
free((char *)q);
}
/* Return the token name or regular expression for a token number. */
char *
#ifdef __USE_PROTOS
TerminalString( int token )
#else
int token;
#endif
{
int j;
static char imag_name[20];
/* look in all lexclasses for the token */
for (j=0; j<NumLexClasses; j++)
{
lexmode(j);
}
if (1) {
return imag_name; /* MR13 */
}
return "invalid";
}
/* S i m p l e I n t S t a c k */
void
#ifdef __USE_PROTOS
pushint( int i )
#else
pushint( i )
int i;
#endif
{
}
int
#ifdef __USE_PROTOS
popint( void )
#else
popint( )
#endif
{
}
int
#ifdef __USE_PROTOS
istacksize( void )
#else
istacksize( )
#endif
{
return MAX_INT_STACK-isp;
}
void
#ifdef __USE_PROTOS
istackreset( void )
#else
istackreset( )
#endif
{
isp = MAX_INT_STACK;
}
int
#ifdef __USE_PROTOS
istackempty( void )
#else
istackempty( )
#endif
{
return isp==MAX_INT_STACK;
}
int
#ifdef __USE_PROTOS
topint( void )
#else
topint( )
#endif
{
}
void
#ifdef __USE_PROTOS
#else
int argc;
char **argv;
#endif
{
Opt *p;
while ( argc-- > 0 )
{
p = options;
{
{
if ( p->arg )
{
/* MR9 26-Sep-97 Check for argv valid */
if (argc-- > 0) {
argv++;
} else {
};
}
else
break;
}
p++;
}
argv++;
}
}
static void
#ifdef __USE_PROTOS
CompleteContextGuards(void)
#else
#endif
{
ListNode * p;
if (ContextGuardPredicateList == NULL) return;
}
}
/* Go back into the syntax diagram and compute all meta tokens; i.e.
* turn all '.', ranges, token class refs etc... into actual token sets
*/
static void
#ifdef __USE_PROTOS
CompleteTokenSetRefs(void)
#else
#endif
{
ListNode *p;
if ( MetaTokenNodes==NULL ) return;
{
set a,b;
if ( q->wild_card )
{
q->tset = all_tokens;
}
{
}
else if ( q->upper_range!=0 )
{
/* we have a range on our hands: make a set from q->token .. q->upper_range */
int i;
a = empty;
/* MR13 */ if (q->complement) {
/* MR13 */ set_free(a);
/* MR13 */ } else {
/* MR13 */ q->tset = a;
/* MR13 */ }
}
/* at this point, it can only be a complemented single token */
else if ( q->complement )
{
b = set_dif(all_tokens, a);
set_free(a);
q->tset=b;
}
else fatal("invalid meta token");
}
}
/* MR10: Jeff Vincent
MR10: Changed to remove directory information from n only if
MR10: if OutputDirectory was changed by user (-o option)
*/
char *
#ifdef __USE_PROTOS
OutMetaName(char *n)
#else
OutMetaName(n)
char *n;
#endif
{
static char *dir_sym = DirectorySymbol;
char *p;
/* If OutputDirectory is same as TopDirectory (platform default) then leave n alone. */
return n;
/* p will point to filename without path information */
p++;
else
p = n;
/* Copy new output directory into newname[] */
/* if new output directory does not have trailing dir_sym, add it! */
}
return newname;
}
char *
#ifdef __USE_PROTOS
pcctsBaseName(char *n) /* MR32 */
#else
char *n;
#endif
{
static char* dir_sym = DirectorySymbol;
int count = 0;
char *p;
p = n;
while ( *p != '\0' ) {p++;} /* go to end of string */
while ( (*p != *dir_sym) && (p != n) ) {--p;} /* Find last DirectorySymbol */
while ( *p == *dir_sym) p++; /* step forward if we're on a dir symbol */
while ( *p != '\0' && *p != '.')
{
p++;
} /* create a new name */
return newname;
}
static void
#ifdef __USE_PROTOS
#else
char *class_c_file;
#endif
{
int i;
for (i=0; i<NumFiles; i++)
{
/* assume that file names are case insensitive */
#else
#endif
{
}
}
}
void
#ifdef __USE_PROTOS
#else
char *err;
#endif
{
}
void
#ifdef __USE_PROTOS
#else
char *f;
int l;
char *err;
#endif
{
}
void
#ifdef __USE_PROTOS
#else
char *err;
#endif
{
/* back up the file number if we hit an error at the end of the last file */
}
void
#ifdef __USE_PROTOS
#else
char *err;
#endif
{
/* back up the file number if we hit an error at the end of the last file */
}
void
#ifdef __USE_PROTOS
#else
char *err;
#endif
{
}
void
#ifdef __USE_PROTOS
#else
char *err;
char *f;
int l;
#endif
{
}
void
#ifdef __USE_PROTOS
#else
char *err;
#endif
{
/* back up the file number if we hit an error at the end of the last file */
}
void
#ifdef __USE_PROTOS
#else
char *err;
#endif
{
/* back up the file number if we hit an error at the end of the last file */
}
#ifdef __USE_PROTOS
newUserAction(char *s)
#else
char *s;
#endif
{
return ua;
}
/* Added by TJP September 1994 */
/* Take in file.h and return file_h; names w/o '.'s are left alone */
char *
#ifdef __USE_PROTOS
gate_symbol(char *name)
#else
char *name;
#endif
{
static char buf[100];
char *p;
for (p=buf; *p!='\0'; p++)
{
if ( *p=='.' ) *p = '_';
}
return buf;
}
char *
#ifdef __USE_PROTOS
#else
int blockid;
int altnum;
#endif
{
static char buf[100];
char *p;
return p;
}