]> git.saurik.com Git - bison.git/blob - src/parse-gram.h
muscle: minor refactoring
[bison.git] / src / parse-gram.h
1 /* A Bison parser, made by GNU Bison 2.7.1127-02879-dirty. */
2
3 /* Bison interface for Yacc-like parsers in C
4
5 Copyright (C) 1984, 1989-1990, 2000-2013 Free Software Foundation, Inc.
6
7 This program is free software: you can redistribute it and/or modify
8 it under the terms of the GNU General Public License as published by
9 the Free Software Foundation, either version 3 of the License, or
10 (at your option) any later version.
11
12 This program is distributed in the hope that it will be useful,
13 but WITHOUT ANY WARRANTY; without even the implied warranty of
14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 GNU General Public License for more details.
16
17 You should have received a copy of the GNU General Public License
18 along with this program. If not, see <http://www.gnu.org/licenses/>. */
19
20 /* As a special exception, you may create a larger work that contains
21 part or all of the Bison parser skeleton and distribute that work
22 under terms of your choice, so long as that work isn't itself a
23 parser generator using the skeleton or a modified version thereof
24 as a parser skeleton. Alternatively, if you modify or redistribute
25 the parser skeleton itself, you may (at your option) remove this
26 special exception, which will cause the skeleton and the resulting
27 Bison output files to be licensed under the GNU General Public
28 License without this special exception.
29
30 This special exception was added by the Free Software Foundation in
31 version 2.2 of Bison. */
32
33 #ifndef YY_GRAM_SRC_PARSE_GRAM_H_INCLUDED
34 # define YY_GRAM_SRC_PARSE_GRAM_H_INCLUDED
35 /* Debug traces. */
36 #ifndef GRAM_DEBUG
37 # if defined YYDEBUG
38 #if YYDEBUG
39 # define GRAM_DEBUG 1
40 # else
41 # define GRAM_DEBUG 0
42 # endif
43 # else /* ! defined YYDEBUG */
44 # define GRAM_DEBUG 1
45 # endif /* ! defined YYDEBUG */
46 #endif /* ! defined GRAM_DEBUG */
47 #if GRAM_DEBUG
48 extern int gram_debug;
49 #endif
50 /* "%code requires" blocks. */
51 #line 219 "src/parse-gram.y" /* yacc.c:1931 */
52
53 # ifndef PARAM_TYPE
54 # define PARAM_TYPE
55 typedef enum
56 {
57 param_none = 0,
58 param_lex = 1 << 0,
59 param_parse = 1 << 1,
60 param_both = param_lex | param_parse
61 } param_type;
62 # endif
63
64
65 #line 66 "src/parse-gram.h" /* yacc.c:1931 */
66
67 /* Token type. */
68 #ifndef GRAM_TOKENTYPE
69 # define GRAM_TOKENTYPE
70 enum gram_tokentype
71 {
72 GRAM_EOF = 0,
73 STRING = 258,
74 INT = 259,
75 PERCENT_TOKEN = 260,
76 PERCENT_NTERM = 261,
77 PERCENT_TYPE = 262,
78 PERCENT_DESTRUCTOR = 263,
79 PERCENT_PRINTER = 264,
80 PERCENT_LEFT = 265,
81 PERCENT_RIGHT = 266,
82 PERCENT_NONASSOC = 267,
83 PERCENT_PRECEDENCE = 268,
84 PERCENT_PREC = 269,
85 PERCENT_DPREC = 270,
86 PERCENT_MERGE = 271,
87 PERCENT_CODE = 272,
88 PERCENT_DEFAULT_PREC = 273,
89 PERCENT_DEFINE = 274,
90 PERCENT_DEFINES = 275,
91 PERCENT_ERROR_VERBOSE = 276,
92 PERCENT_EXPECT = 277,
93 PERCENT_EXPECT_RR = 278,
94 PERCENT_FLAG = 279,
95 PERCENT_FILE_PREFIX = 280,
96 PERCENT_GLR_PARSER = 281,
97 PERCENT_INITIAL_ACTION = 282,
98 PERCENT_LANGUAGE = 283,
99 PERCENT_NAME_PREFIX = 284,
100 PERCENT_NO_DEFAULT_PREC = 285,
101 PERCENT_NO_LINES = 286,
102 PERCENT_NONDETERMINISTIC_PARSER = 287,
103 PERCENT_OUTPUT = 288,
104 PERCENT_REQUIRE = 289,
105 PERCENT_SKELETON = 290,
106 PERCENT_START = 291,
107 PERCENT_TOKEN_TABLE = 292,
108 PERCENT_VERBOSE = 293,
109 PERCENT_YACC = 294,
110 BRACED_CODE = 295,
111 BRACED_PREDICATE = 296,
112 BRACKETED_ID = 297,
113 CHAR = 298,
114 EPILOGUE = 299,
115 EQUAL = 300,
116 ID = 301,
117 ID_COLON = 302,
118 PERCENT_PERCENT = 303,
119 PIPE = 304,
120 PROLOGUE = 305,
121 SEMICOLON = 306,
122 TAG = 307,
123 TAG_ANY = 308,
124 TAG_NONE = 309,
125 PERCENT_PARAM = 310,
126 PERCENT_UNION = 311,
127 PERCENT_EMPTY = 312
128 };
129 #endif
130
131 /* Value type. */
132 #if ! defined GRAM_STYPE && ! defined GRAM_STYPE_IS_DECLARED
133 typedef union GRAM_STYPE GRAM_STYPE;
134 union GRAM_STYPE
135 {
136 #line 105 "src/parse-gram.y" /* yacc.c:1931 */
137
138 assoc assoc;
139 char *code;
140 char const *chars;
141 int integer;
142 named_ref *named_ref;
143 symbol *symbol;
144 symbol_list *list;
145 uniqstr uniqstr;
146 unsigned char character;
147
148 #line 243 "src/parse-gram.y" /* yacc.c:1931 */
149
150 param_type param;
151
152 #line 419 "src/parse-gram.y" /* yacc.c:1931 */
153 code_props_type code_type;
154
155 #line 156 "src/parse-gram.h" /* yacc.c:1931 */
156 };
157 # define GRAM_STYPE_IS_TRIVIAL 1
158 # define GRAM_STYPE_IS_DECLARED 1
159 #endif
160
161 /* Location type. */
162 #if ! defined GRAM_LTYPE && ! defined GRAM_LTYPE_IS_DECLARED
163 typedef struct GRAM_LTYPE GRAM_LTYPE;
164 struct GRAM_LTYPE
165 {
166 int first_line;
167 int first_column;
168 int last_line;
169 int last_column;
170 };
171 # define GRAM_LTYPE_IS_DECLARED 1
172 # define GRAM_LTYPE_IS_TRIVIAL 1
173 #endif
174
175
176
177 int gram_parse (void);
178
179 #endif /* !YY_GRAM_SRC_PARSE_GRAM_H_INCLUDED */