#include <stdio.h>
#include <stdlib.h>
#include <strings.h>
#include <iostream>
#include "../include/vars.h"
#include "../include/parser.h"
#include "../include/util.h"
Classes | |
union | YYSTYPE |
struct | yyltype |
Defines | |
#define | YYBISON 1 |
#define | NUM 258 |
#define | STR 259 |
#define | GE 260 |
#define | LE 261 |
#define | UE 262 |
#define | ID 263 |
#define | EQEQ 264 |
#define | ASSIGN 265 |
#define | PRINT 266 |
#define | IF 267 |
#define | DO 268 |
#define | NEWLINE 269 |
#define | THEN 270 |
#define | ELSE 271 |
#define | WHILE 272 |
#define | ENDIF 273 |
#define | ENDWHILE 274 |
#define | RUN 275 |
#define | POSROT 276 |
#define | SCRIPT 277 |
#define | TORQUE 278 |
#define | ABS 279 |
#define | SIN 280 |
#define | COS 281 |
#define | ASIN 282 |
#define | ACOS 283 |
#define | TAN 284 |
#define | ATAN 285 |
#define | SLEEP 286 |
#define | SENSOR 287 |
#define | STOP 288 |
#define | WAIT 289 |
#define | MOTION 290 |
#define | PLAY 291 |
#define | LOAD 292 |
#define | POS 293 |
#define | ARML 294 |
#define | ARMR 295 |
#define | LEGL 296 |
#define | LEGR 297 |
#define | MOVETO 298 |
#define | COLLISION 299 |
#define | TIME 300 |
#define | SYNC 301 |
#define | ENDSYNC 302 |
#define | HOLD 303 |
#define | GET 304 |
#define | SET 305 |
#define | UMINUS 306 |
#define | YYLTYPE yyltype |
#define | const |
#define | YYFINAL 277 |
#define | YYFLAG -32768 |
#define | YYNTBASE 66 |
#define | YYTRANSLATE(x) ((unsigned)(x) <= 306 ? yytranslate[x] : 71) |
#define | YYLAST 1845 |
#define | yyerrok (yyerrstatus = 0) |
#define | yyclearin (yychar = YYEMPTY) |
#define | YYEMPTY -2 |
#define | YYEOF 0 |
#define | YYACCEPT return(0) |
#define | YYABORT return(1) |
#define | YYERROR goto yyerrlab1 |
#define | YYFAIL goto yyerrlab |
#define | YYRECOVERING() (!!yyerrstatus) |
#define | YYBACKUP(token, value) |
#define | YYTERROR 1 |
#define | YYERRCODE 256 |
#define | YYLEX yylex() |
#define | YYINITDEPTH 200 |
#define | YYMAXDEPTH 10000 |
#define | YYPARSE_PARAM_DECL |
#define | YYPOPSTACK (yyvsp--, yyssp--) |
Functions | |
void | yyerror (char *msg) |
void | yyrestart (FILE *f) |
int | yyparse () |
int | yylex () |
int | yywrap () |
static void | __yy_memcpy (char *from, char *to, int count) |
int | yyparse (YYPARSE_PARAM) |
Variables | |
int | temp |
static const char | yytranslate [] |
static const short | yyr1 [] |
static const short | yyr2 [] |
static const short | yydefact [] |
static const short | yydefgoto [] |
static const short | yypact [] |
static const short | yypgoto [] |
static const short | yytable [] |
static const short | yycheck [] |
int | yychar |
YYSTYPE | yylval |
int | yynerrs |
#define ABS 279 |
#define ACOS 283 |
#define ARML 294 |
#define ARMR 295 |
#define ASIN 282 |
#define ASSIGN 265 |
#define ATAN 285 |
#define COLLISION 299 |
#define const |
#define COS 281 |
#define DO 268 |
#define ELSE 271 |
#define ENDIF 273 |
#define ENDSYNC 302 |
#define ENDWHILE 274 |
#define EQEQ 264 |
#define GE 260 |
#define GET 304 |
#define HOLD 303 |
#define ID 263 |
#define IF 267 |
#define LE 261 |
#define LEGL 296 |
#define LEGR 297 |
#define LOAD 292 |
#define MOTION 290 |
#define MOVETO 298 |
#define NEWLINE 269 |
#define NUM 258 |
#define PLAY 291 |
#define POS 293 |
#define POSROT 276 |
#define PRINT 266 |
#define RUN 275 |
#define SCRIPT 277 |
#define SENSOR 287 |
#define SET 305 |
#define SIN 280 |
#define SLEEP 286 |
#define STOP 288 |
#define STR 259 |
#define SYNC 301 |
#define TAN 284 |
#define THEN 270 |
#define TIME 300 |
#define TORQUE 278 |
#define UE 262 |
#define UMINUS 306 |
#define WAIT 289 |
#define WHILE 272 |
#define YYABORT return(1) |
#define YYACCEPT return(0) |
#define YYBACKUP | ( | token, | |||
value | ) |
Value:
do \ if (yychar == YYEMPTY && yylen == 1) \ { yychar = (token), yylval = (value); \ yychar1 = YYTRANSLATE (yychar); \ YYPOPSTACK; \ goto yybackup; \ } \ else \ { yyerror ("syntax error: cannot back up"); YYERROR; } \ while (0)
#define YYBISON 1 |
#define yyclearin (yychar = YYEMPTY) |
#define YYEMPTY -2 |
#define YYEOF 0 |
#define YYERRCODE 256 |
#define yyerrok (yyerrstatus = 0) |
#define YYERROR goto yyerrlab1 |
#define YYFAIL goto yyerrlab |
#define YYFINAL 277 |
#define YYFLAG -32768 |
#define YYINITDEPTH 200 |
#define YYLAST 1845 |
#define YYLEX yylex() |
#define YYLTYPE yyltype |
#define YYMAXDEPTH 10000 |
#define YYNTBASE 66 |
#define YYPARSE_PARAM_DECL |
#define YYPOPSTACK (yyvsp--, yyssp--) |
#define YYRECOVERING | ( | ) | (!!yyerrstatus) |
#define YYTERROR 1 |
#define YYTRANSLATE | ( | x | ) | ((unsigned)(x) <= 306 ? yytranslate[x] : 71) |
static void __yy_memcpy | ( | char * | from, | |
char * | to, | |||
int | count | |||
) | [static] |
void yyerror | ( | char * | msg | ) |
int yylex | ( | ) |
int yyparse | ( | YYPARSE_PARAM | ) |
int yyparse | ( | ) |
void yyrestart | ( | FILE * | f | ) |
int yywrap | ( | ) |
int temp |
int yychar |
const short yycheck[] [static] |
const short yydefact[] [static] |
Initial value:
{ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 0, 50, 49, 48, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 33, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 37, 38, 0, 36, 55, 56, 54, 53, 0, 0, 0, 31, 32, 52, 51, 35, 34, 0, 0, 0, 0, 0, 15, 14, 0, 0, 0, 0, 0, 0, 0, 0, 20, 16, 0, 10, 11, 8, 39, 40, 41, 43, 42, 44, 45, 0, 47, 0, 60, 0, 0, 57, 58, 0, 0, 0, 13, 12, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 29, 30, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 46, 59, 0, 0, 5, 0, 17, 0, 21, 0, 0, 0, 0, 0, 0, 28, 6, 0, 0, 0, 0, 0, 0, 0, 0, 19, 18, 0, 0, 0, 0, 0, 9, 0, 0, 0, 0, 0, 22, 23, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 26, 0, 0, 0, 0, 0, 0, 0, 0, 0, 24, 25, 0, 0, 27, 0, 0 }
const short yydefgoto[] [static] |
Initial value:
{ 21, 96, 199, 22, 200 }
int yynerrs |
const short yypact[] [static] |
Initial value:
{ 1795, -8, -60, 342, 342, -57, -56, -55, -54, -53, -52, -51, -50, -49, -48, -47, -46, -45, 1795, -42, -41, 1590,-32768, 342, 254,-32768,-32768,-32768, -40, -39, -38, -37, -36, -35, -34, -33, -32, -31, -30, -29, -28, 342, 342, 1477, 1512, 298, 33, 342, -24, -22, 41, 342, 342, 342, 342, 342, 342, 342, 1672, -19, 342, -32768, 694, -4, 6, 130, 342, 342, 342, 342, 342, 342, 342, 342, 43, 342, 9, 11, 342, -2, 161, 342, 342, 342, 342, 1795, 26, 31, 342, 342, 342, 342, 342, 342, 1795, 342, 23, 1531, 28, 184, 32, 34, 30, 727, 749, 784, 806, 817, 841, 874, 35, 36, 898,-32768, 37, 38, 39, 370, 388, 403, 424, 442, 457, 478, 909, 29, 931,-32768,-32768, 496,-32768, -2, -2, 1531, -2, 1631, 342, 342, -2, -2, -2, -2, 89, 89, 1713, 966, 342, 40, 49,-32768,-32768, 342, 342, 109, 342, 342, 342, 342, 342,-32768,-32768, 342,-32768,-32768,-32768,-32768,-32768,-32768,-32768,-32768,-32768, -32768, 342,-32768, 111,-32768, 1795, 56, 118, 118, 57, 342, 988,-32768,-32768, 511, 999, 51, 1023, 1056, 1080, 1091, 1113, 1148, 532, 63, 1754,-32768,-32768,-32768, 712, 342, 58, 342, 59, 342, 342, 342, 342, 342, 342, -32768,-32768, 66, 342,-32768, 550,-32768, 565,-32768, 1170, 1181, 1205, 1238, 1262, 586,-32768,-32768, 67, 68, 342, 342, 342, 342, 342, 69,-32768,-32768, 604, 619, 1273, 1295, 1330,-32768, 75, 77, 342, 342, 342,-32768,-32768, 1352, 1363, 53, 342, 342, 342, 78, 1387, 1420, 1444, -32768, 342, 342, 342, 640, 658, 1455, 79, 81, 342, -32768,-32768, 673, 82,-32768, 146,-32768 }
const short yypgoto[] [static] |
Initial value:
{ -12, -32768, -67, -18, -3 }
const short yyr1[] [static] |
Initial value:
{ 0, 66, 66, 67, 67, 68, 68, 69, 69, 69, 69, 69, 69, 69, 69, 69, 69, 69, 69, 69, 69, 69, 69, 69, 69, 69, 69, 69, 69, 69, 69, 70, 70, 70, 70, 70, 70, 70, 70, 70, 70, 70, 70, 70, 70, 70, 70, 70, 70, 70, 70, 70, 70, 70, 70, 70, 70, 70, 70, 70, 70 }
const short yyr2[] [static] |
Initial value:
{ 0, 2, 1, 1, 4, 2, 3, 4, 5, 9, 5, 5, 5, 5, 4, 4, 4, 7, 9, 9, 4, 7, 11, 11, 17, 17, 13, 19, 8, 6, 6, 3, 3, 2, 3, 3, 3, 3, 3, 4, 4, 4, 4, 4, 4, 4, 6, 4, 1, 1, 1, 3, 3, 3, 3, 3, 3, 4, 4, 6, 4 }
const short yytable[] [static] |
const char yytranslate[] [static] |