mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2024-12-19 01:34:32 +00:00
68a24bdba4
These changes modify the makefiles so that the output of flex and bison are placed in the SRC directory, not the OBJ directory. It is intended that they be checked in as any other LLVM source so that platforms without convenient access to flex/bison can be compiled. From now on, if you change a .y or .l file you *must* also commit the generated .cpp and .h files. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@23115 91177308-0d34-0410-b5e6-96231b3b80d8
204 lines
4.4 KiB
C
204 lines
4.4 KiB
C
/* A Bison parser, made by GNU Bison 1.875c. */
|
|
|
|
/* Skeleton parser for Yacc-like parsing with Bison,
|
|
Copyright (C) 1984, 1989, 1990, 2000, 2001, 2002, 2003 Free Software Foundation, Inc.
|
|
|
|
This program is free software; you can redistribute it and/or modify
|
|
it under the terms of the GNU General Public License as published by
|
|
the Free Software Foundation; either version 2, or (at your option)
|
|
any later version.
|
|
|
|
This program is distributed in the hope that it will be useful,
|
|
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
GNU General Public License for more details.
|
|
|
|
You should have received a copy of the GNU General Public License
|
|
along with this program; if not, write to the Free Software
|
|
Foundation, Inc., 59 Temple Place - Suite 330,
|
|
Boston, MA 02111-1307, USA. */
|
|
|
|
/* As a special exception, when this file is copied by Bison into a
|
|
Bison output file, you may use that output file without restriction.
|
|
This special exception was added by the Free Software Foundation
|
|
in version 1.24 of Bison. */
|
|
|
|
/* Tokens. */
|
|
#ifndef YYTOKENTYPE
|
|
# define YYTOKENTYPE
|
|
/* Put the tokens into the symbol table, so that GDB and other debuggers
|
|
know about them. */
|
|
enum yytokentype {
|
|
INTEGER = 258,
|
|
STRING = 259,
|
|
IDENTIFIER = 260,
|
|
SEMI = 261,
|
|
COLON = 262,
|
|
FORWARD = 263,
|
|
MAIN = 264,
|
|
DUMP = 265,
|
|
TRUETOK = 266,
|
|
FALSETOK = 267,
|
|
LESS = 268,
|
|
MORE = 269,
|
|
LESS_EQUAL = 270,
|
|
MORE_EQUAL = 271,
|
|
NOT_EQUAL = 272,
|
|
EQUAL = 273,
|
|
PLUS = 274,
|
|
MINUS = 275,
|
|
INCR = 276,
|
|
DECR = 277,
|
|
MULT = 278,
|
|
DIV = 279,
|
|
MODULUS = 280,
|
|
NEGATE = 281,
|
|
ABS = 282,
|
|
MIN = 283,
|
|
MAX = 284,
|
|
STAR_SLASH = 285,
|
|
AND = 286,
|
|
OR = 287,
|
|
XOR = 288,
|
|
LSHIFT = 289,
|
|
RSHIFT = 290,
|
|
DROP = 291,
|
|
DROP2 = 292,
|
|
NIP = 293,
|
|
NIP2 = 294,
|
|
DUP = 295,
|
|
DUP2 = 296,
|
|
SWAP = 297,
|
|
SWAP2 = 298,
|
|
OVER = 299,
|
|
OVER2 = 300,
|
|
ROT = 301,
|
|
ROT2 = 302,
|
|
RROT = 303,
|
|
RROT2 = 304,
|
|
TUCK = 305,
|
|
TUCK2 = 306,
|
|
ROLL = 307,
|
|
PICK = 308,
|
|
SELECT = 309,
|
|
MALLOC = 310,
|
|
FREE = 311,
|
|
GET = 312,
|
|
PUT = 313,
|
|
IF = 314,
|
|
ELSE = 315,
|
|
ENDIF = 316,
|
|
WHILE = 317,
|
|
END = 318,
|
|
RECURSE = 319,
|
|
RETURN = 320,
|
|
EXIT = 321,
|
|
TAB = 322,
|
|
SPACE = 323,
|
|
CR = 324,
|
|
IN_STR = 325,
|
|
IN_NUM = 326,
|
|
IN_CHAR = 327,
|
|
OUT_STR = 328,
|
|
OUT_NUM = 329,
|
|
OUT_CHAR = 330
|
|
};
|
|
#endif
|
|
#define INTEGER 258
|
|
#define STRING 259
|
|
#define IDENTIFIER 260
|
|
#define SEMI 261
|
|
#define COLON 262
|
|
#define FORWARD 263
|
|
#define MAIN 264
|
|
#define DUMP 265
|
|
#define TRUETOK 266
|
|
#define FALSETOK 267
|
|
#define LESS 268
|
|
#define MORE 269
|
|
#define LESS_EQUAL 270
|
|
#define MORE_EQUAL 271
|
|
#define NOT_EQUAL 272
|
|
#define EQUAL 273
|
|
#define PLUS 274
|
|
#define MINUS 275
|
|
#define INCR 276
|
|
#define DECR 277
|
|
#define MULT 278
|
|
#define DIV 279
|
|
#define MODULUS 280
|
|
#define NEGATE 281
|
|
#define ABS 282
|
|
#define MIN 283
|
|
#define MAX 284
|
|
#define STAR_SLASH 285
|
|
#define AND 286
|
|
#define OR 287
|
|
#define XOR 288
|
|
#define LSHIFT 289
|
|
#define RSHIFT 290
|
|
#define DROP 291
|
|
#define DROP2 292
|
|
#define NIP 293
|
|
#define NIP2 294
|
|
#define DUP 295
|
|
#define DUP2 296
|
|
#define SWAP 297
|
|
#define SWAP2 298
|
|
#define OVER 299
|
|
#define OVER2 300
|
|
#define ROT 301
|
|
#define ROT2 302
|
|
#define RROT 303
|
|
#define RROT2 304
|
|
#define TUCK 305
|
|
#define TUCK2 306
|
|
#define ROLL 307
|
|
#define PICK 308
|
|
#define SELECT 309
|
|
#define MALLOC 310
|
|
#define FREE 311
|
|
#define GET 312
|
|
#define PUT 313
|
|
#define IF 314
|
|
#define ELSE 315
|
|
#define ENDIF 316
|
|
#define WHILE 317
|
|
#define END 318
|
|
#define RECURSE 319
|
|
#define RETURN 320
|
|
#define EXIT 321
|
|
#define TAB 322
|
|
#define SPACE 323
|
|
#define CR 324
|
|
#define IN_STR 325
|
|
#define IN_NUM 326
|
|
#define IN_CHAR 327
|
|
#define OUT_STR 328
|
|
#define OUT_NUM 329
|
|
#define OUT_CHAR 330
|
|
|
|
|
|
|
|
|
|
#if ! defined (YYSTYPE) && ! defined (YYSTYPE_IS_DECLARED)
|
|
#line 35 "/proj/llvm/build/projects/Stacker/../../../llvm/projects/Stacker/lib/compiler/StackerParser.y"
|
|
typedef union YYSTYPE {
|
|
llvm::Module* ModuleVal;
|
|
llvm::Function* FunctionVal;
|
|
llvm::BasicBlock* BasicBlockVal;
|
|
int64_t IntegerVal;
|
|
char* StringVal;
|
|
} YYSTYPE;
|
|
/* Line 1275 of yacc.c. */
|
|
#line 195 "StackerParser.tab.h"
|
|
# define yystype YYSTYPE /* obsolescent; will be withdrawn */
|
|
# define YYSTYPE_IS_DECLARED 1
|
|
# define YYSTYPE_IS_TRIVIAL 1
|
|
#endif
|
|
|
|
extern YYSTYPE Stackerlval;
|
|
|
|
|
|
|