ack/util/LLgen/src/global.c

71 lines
1.3 KiB
C
Raw Normal View History

1984-10-08 14:14:53 +00:00
/*
1987-03-10 01:26:51 +00:00
* (c) copyright 1987 by the Vrije Universiteit, Amsterdam, The Netherlands.
* See the copyright notice in the ACK home directory, in the file "Copyright".
1984-10-08 14:14:53 +00:00
*
*/
/*
* L L G E N
*
* An Extended LL(1) Parser Generator
*
* Author : Ceriel J.H. Jacobs
*/
/*
* global.c
* Contains declarations visible in several other source files
*/
# include "types.h"
# include "extern.h"
1984-10-08 14:14:53 +00:00
# include "io.h"
1984-10-08 17:11:03 +00:00
# ifndef NORCSID
static string rcsid4 = "$Header$";
# endif
1984-10-08 14:14:53 +00:00
char ltext[LTEXTSZ];
p_nont nonterms;
p_nont maxnt;
1984-10-08 14:14:53 +00:00
int nnonterms;
p_token tokens;
p_token maxt;
int ntokens;
1987-05-12 18:23:09 +00:00
int nterms, nalts;
p_order porder, sorder;
1984-10-08 14:14:53 +00:00
p_start start;
int linecount;
int assval;
FILE *fout;
FILE *fpars;
FILE *finput;
FILE *fact;
char f_pars[] = PARSERFILE;
char f_temp[] = ACTFILE;
char f_out[20];
1984-10-08 14:14:53 +00:00
string f_input;
char f_include[20];
char f_rec[20];
1984-10-08 14:14:53 +00:00
string e_noopen = "Cannot open %s";
int verbose;
1987-11-27 11:04:07 +00:00
int wflag;
1984-10-08 14:14:53 +00:00
string lexical;
string prefix;
string onerror;
1984-10-08 14:14:53 +00:00
int ntneeded;
int ntprint;
# ifndef NDEBUG
int debug;
# endif not NDEBUG
p_file files;
p_file maxfiles;
1984-10-08 14:14:53 +00:00
p_file pfile;
string LLgenid = "/* LLgen generated code from source %s */\n";
t_token lextoken;
int nerrors;
string rec_file, incl_file;
1988-06-22 16:23:36 +00:00
int low_percentage = 10, high_percentage = 30;
int min_cases_for_jmptable = 8;
int jmptable_option;