ergo
ergo_input_processor.c File Reference

Parses the input. More...

#include <stdio.h>
#include <stdlib.h>
#include <math.h>
#include "ergo_scripted.h"
#include <string.h>

Classes

union  YYSTYPE
 
struct  YYSTACKDATA
 

Macros

#define YYBYACC   1
 
#define YYMAJOR   1
 
#define YYMINOR   9
 
#define YYPATCH   20110908
 
#define YYEMPTY   (-1)
 
#define yyclearin   (yychar = YYEMPTY)
 
#define yyerrok   (yyerrflag = 0)
 
#define YYRECOVERING()   (yyerrflag != 0)
 
#define YYPREFIX   "yy"
 
#define YYPURE   0
 
#define YYERROR_VERBOSE
 
#define YYSTYPE_IS_DECLARED   1
 
#define YYPARSE_DECL()   yyparse(void)
 
#define YYLEX_DECL()   yylex(void)
 
#define YYLEX   yylex()
 
#define YYERROR_DECL()   yyerror(const char *s)
 
#define YYERROR_CALL(msg)   yyerror(msg)
 
#define NUMBER   257
 
#define DOT   258
 
#define SYMBOL   259
 
#define EQUAL   260
 
#define STRING   261
 
#define EOFTAG   262
 
#define GETEXC   263
 
#define GETPOL   264
 
#define K_ALL   265
 
#define HELP   266
 
#define MOLTAG   267
 
#define GHOSTTAG   268
 
#define MOLDAL   269
 
#define QUIT   270
 
#define RUNTAG   271
 
#define SYSTEM   272
 
#define GHOST   273
 
#define ANGSTROM   274
 
#define PRECISION   275
 
#define RANGE   276
 
#define WARRANTY   277
 
#define SET_NTHREADS   278
 
#define PLUS   279
 
#define MINUS   280
 
#define TIMES   281
 
#define DIVIDE   282
 
#define POWER   283
 
#define LEFT_PARENTHESIS   284
 
#define RIGHT_PARENTHESIS   285
 
#define EOL   286
 
#define NEG   287
 
#define YYERRCODE   256
 
#define YYTABLESIZE   319
 
#define YYFINAL   16
 
#define YYDEBUG   0
 
#define YYMAXTOKEN   287
 
#define YYSTACKSIZE   500
 
#define YYMAXDEPTH   500
 
#define YYINITSTACKSIZE   500
 
#define yyfreestack(data)   /* nothing */
 
#define YYABORT   goto yyabort
 
#define YYREJECT   goto yyabort
 
#define YYACCEPT   goto yyaccept
 
#define YYERROR   goto yyerrlab
 

Functions

int yylex (void)
 
int yyerror (const char *s)
 
static int yygrowstack (YYSTACKDATA *data)
 

Variables

static const char yysccsid [] = "@(#)yaccpar 1.9 (Berkeley) 02/21/93"
 
static const char * last_token = NULL
 
static const short yylhs []
 
static const short yylen []
 
static const short yydefred []
 
static const short yydgoto []
 
static const short yysindex []
 
static const short yyrindex []
 
static const short yygindex []
 
static const short yytable []
 
static const short yycheck []
 
int yydebug
 
int yynerrs
 
int yyerrflag
 
int yychar
 
YYSTYPE yyval
 
YYSTYPE yylval
 
static YYSTACKDATA yystack
 
int ergo_scanner_lineno = 1
 
int ergo_scanner_reading_stdin = 0
 

Detailed Description

Parses the input.

Uses bison code generator to generate the parses.

Macro Definition Documentation

#define ANGSTROM   274

Referenced by while().

#define DIVIDE   282

Referenced by while().

#define DOT   258

Referenced by while().

#define EOFTAG   262

Referenced by while().

#define EOL   286

Referenced by while().

#define EQUAL   260

Referenced by while().

#define GETEXC   263

Referenced by while().

#define GETPOL   264

Referenced by while().

#define GHOST   273

Referenced by while().

#define GHOSTTAG   268
#define HELP   266

Referenced by while().

#define K_ALL   265

Referenced by while().

#define LEFT_PARENTHESIS   284

Referenced by while().

#define MINUS   280

Referenced by while().

#define MOLDAL   269

Referenced by while().

#define MOLTAG   267

Referenced by while().

#define NEG   287
#define NUMBER   257

Referenced by while().

#define PLUS   279

Referenced by while().

#define POWER   283

Referenced by while().

#define PRECISION   275

Referenced by while().

#define QUIT   270

Referenced by while().

#define RANGE   276

Referenced by while().

#define RIGHT_PARENTHESIS   285

Referenced by while().

#define RUNTAG   271

Referenced by while().

#define SET_NTHREADS   278

Referenced by while().

#define STRING   261

Referenced by while().

#define SYMBOL   259

Referenced by while().

#define SYSTEM   272

Referenced by while().

#define TIMES   281

Referenced by while().

#define WARRANTY   277

Referenced by while().

#define YYABORT   goto yyabort
#define YYACCEPT   goto yyaccept
#define YYBYACC   1
#define yyclearin   (yychar = YYEMPTY)
#define YYDEBUG   0
#define YYEMPTY   (-1)
#define YYERRCODE   256
#define yyerrok   (yyerrflag = 0)
#define YYERROR   goto yyerrlab
#define YYERROR_CALL (   msg)    yyerror(msg)
#define YYERROR_DECL ( )    yyerror(const char *s)
#define YYERROR_VERBOSE
#define YYFINAL   16
#define yyfreestack (   data)    /* nothing */
#define YYINITSTACKSIZE   500

Referenced by yygrowstack().

#define YYLEX   yylex()
#define YYLEX_DECL ( )    yylex(void)
#define YYMAJOR   1
#define YYMAXDEPTH   500

Referenced by yygrowstack().

#define YYMAXTOKEN   287
#define YYMINOR   9
int YYPARSE_DECL ( )    yyparse(void)
#define YYPATCH   20110908
#define YYPREFIX   "yy"
#define YYPURE   0
#define YYRECOVERING ( )    (yyerrflag != 0)
#define YYREJECT   goto yyabort
#define YYSTACKSIZE   500
#define YYSTYPE_IS_DECLARED   1
#define YYTABLESIZE   319

Function Documentation

int yyerror ( const char *  s)
int yylex ( void  )

Variable Documentation

int ergo_scanner_lineno = 1

Referenced by while(), and yyerror().

int ergo_scanner_reading_stdin = 0

Referenced by ergo_parse_file(), while(), and yyerror().

const char* last_token = NULL
static

Referenced by yyerror().

int yychar
const short yycheck[]
static
int yydebug
const short yydefred[]
static
Initial value:
= { 0,
7, 10, 0, 0, 0, 0, 0, 0, 29, 0,
0, 18, 0, 25, 0, 0, 0, 0, 5, 6,
0, 0, 0, 0, 0, 0, 0, 19, 0, 21,
24, 0, 0, 0, 0, 0, 0, 26, 0, 0,
0, 0, 32, 12, 0, 0, 14, 20, 0, 0,
35, 0, 0, 0, 0, 11, 9, 0, 3, 27,
28, 13, 0, 33, 15, 0, 0, 23, 0, 0,
0, 0, 0, 0, 0, 22, 0, 0, 0, 42,
0, 0, 0, 0, 0, 0, 30, 0, 34, 31,
}
const short yydgoto[]
static
Initial value:
= { 16,
55, 17, 18, 19, 20, 44, 45,
}
int yyerrflag
const short yygindex[]
static
Initial value:
= { 76,
-34, 109, 0, 0, 0, 24, 0,
}
const short yylen[]
static
Initial value:
= { 2,
0, 1, 3, 0, 1, 1, 1, 3, 3, 1,
3, 3, 4, 3, 4, 1, 2, 1, 2, 3,
2, 4, 4, 2, 1, 3, 4, 4, 1, 6,
7, 1, 2, 5, 1, 3, 3, 3, 3, 2,
3, 3,
}
const short yylhs[]
static
Initial value:
= { -1,
0, 0, 0, 3, 3, 3, 3, 4, 4, 2,
2, 5, 5, 5, 5, 5, 5, 5, 5, 5,
5, 5, 5, 5, 5, 5, 5, 5, 5, 5,
5, 6, 6, 7, 1, 1, 1, 1, 1, 1,
1, 1,
}
YYSTYPE yylval

Referenced by while().

int yynerrs
const short yyrindex[]
static
Initial value:
= { 6,
0, 0, 0, 0, 7, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 111, 0, 0,
0, 0, 14, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 6, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 15, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 1, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
29, 33, 9, 17, 25, 0, 0, 0, 0, 0,
}
const char yysccsid[] = "@(#)yaccpar 1.9 (Berkeley) 02/21/93"
static
const short yysindex[]
static
Initial value:
= { -214,
0, 0, -243, -229, -225, -264, -258, -237, 0, -217,
-213, 0, -252, 0, -238, 0, -247, -227, 0, 0,
-197, -218, -182, -203, -169, -195, -169, 0, -167, 0,
0, -168, -162, -257, -163, -249, -214, 0, -160, -159,
-169, -158, 0, 0, -169, -169, 0, 0, -157, -156,
0, -184, -254, -254, -208, 0, 0, -194, 0, 0,
0, 0, -155, 0, 0, -154, -152, 0, -177, -201,
-254, -254, -254, -254, -254, 0, -150, -153, -148, 0,
-215, -215, -177, -177, -177, -176, 0, -149, 0, 0,
}
YYSTACKDATA yystack
static
const short yytable[]
static
YYSTYPE yyval