1b8e80941Smrg/* A Bison parser, made by GNU Bison 3.2.4.  */
2b8e80941Smrg
3b8e80941Smrg/* Bison interface for Yacc-like parsers in C
4b8e80941Smrg
5b8e80941Smrg   Copyright (C) 1984, 1989-1990, 2000-2015, 2018 Free Software Foundation, Inc.
6b8e80941Smrg
7b8e80941Smrg   This program is free software: you can redistribute it and/or modify
8b8e80941Smrg   it under the terms of the GNU General Public License as published by
9b8e80941Smrg   the Free Software Foundation, either version 3 of the License, or
10b8e80941Smrg   (at your option) any later version.
11b8e80941Smrg
12b8e80941Smrg   This program is distributed in the hope that it will be useful,
13b8e80941Smrg   but WITHOUT ANY WARRANTY; without even the implied warranty of
14b8e80941Smrg   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
15b8e80941Smrg   GNU General Public License for more details.
16b8e80941Smrg
17b8e80941Smrg   You should have received a copy of the GNU General Public License
18b8e80941Smrg   along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
19b8e80941Smrg
20b8e80941Smrg/* As a special exception, you may create a larger work that contains
21b8e80941Smrg   part or all of the Bison parser skeleton and distribute that work
22b8e80941Smrg   under terms of your choice, so long as that work isn't itself a
23b8e80941Smrg   parser generator using the skeleton or a modified version thereof
24b8e80941Smrg   as a parser skeleton.  Alternatively, if you modify or redistribute
25b8e80941Smrg   the parser skeleton itself, you may (at your option) remove this
26b8e80941Smrg   special exception, which will cause the skeleton and the resulting
27b8e80941Smrg   Bison output files to be licensed under the GNU General Public
28b8e80941Smrg   License without this special exception.
29b8e80941Smrg
30b8e80941Smrg   This special exception was added by the Free Software Foundation in
31b8e80941Smrg   version 2.2 of Bison.  */
32b8e80941Smrg
33b8e80941Smrg/* Undocumented macros, especially those whose name start with YY_,
34b8e80941Smrg   are private implementation details.  Do not rely on them.  */
35b8e80941Smrg
36b8e80941Smrg#ifndef YY__MESA_GLSL_SRC_COMPILER_GLSL_GLSL_PARSER_H_INCLUDED
37b8e80941Smrg# define YY__MESA_GLSL_SRC_COMPILER_GLSL_GLSL_PARSER_H_INCLUDED
38b8e80941Smrg/* Debug traces.  */
39b8e80941Smrg#ifndef YYDEBUG
40b8e80941Smrg# define YYDEBUG 0
41b8e80941Smrg#endif
42b8e80941Smrg#if YYDEBUG
43b8e80941Smrgextern int _mesa_glsl_debug;
44b8e80941Smrg#endif
45b8e80941Smrg
46b8e80941Smrg/* Token type.  */
47b8e80941Smrg#ifndef YYTOKENTYPE
48b8e80941Smrg# define YYTOKENTYPE
49b8e80941Smrg  enum yytokentype
50b8e80941Smrg  {
51b8e80941Smrg    ATTRIBUTE = 258,
52b8e80941Smrg    CONST_TOK = 259,
53b8e80941Smrg    BASIC_TYPE_TOK = 260,
54b8e80941Smrg    BREAK = 261,
55b8e80941Smrg    BUFFER = 262,
56b8e80941Smrg    CONTINUE = 263,
57b8e80941Smrg    DO = 264,
58b8e80941Smrg    ELSE = 265,
59b8e80941Smrg    FOR = 266,
60b8e80941Smrg    IF = 267,
61b8e80941Smrg    DISCARD = 268,
62b8e80941Smrg    RETURN = 269,
63b8e80941Smrg    SWITCH = 270,
64b8e80941Smrg    CASE = 271,
65b8e80941Smrg    DEFAULT = 272,
66b8e80941Smrg    CENTROID = 273,
67b8e80941Smrg    IN_TOK = 274,
68b8e80941Smrg    OUT_TOK = 275,
69b8e80941Smrg    INOUT_TOK = 276,
70b8e80941Smrg    UNIFORM = 277,
71b8e80941Smrg    VARYING = 278,
72b8e80941Smrg    SAMPLE = 279,
73b8e80941Smrg    NOPERSPECTIVE = 280,
74b8e80941Smrg    FLAT = 281,
75b8e80941Smrg    SMOOTH = 282,
76b8e80941Smrg    IMAGE1DSHADOW = 283,
77b8e80941Smrg    IMAGE2DSHADOW = 284,
78b8e80941Smrg    IMAGE1DARRAYSHADOW = 285,
79b8e80941Smrg    IMAGE2DARRAYSHADOW = 286,
80b8e80941Smrg    COHERENT = 287,
81b8e80941Smrg    VOLATILE = 288,
82b8e80941Smrg    RESTRICT = 289,
83b8e80941Smrg    READONLY = 290,
84b8e80941Smrg    WRITEONLY = 291,
85b8e80941Smrg    SHARED = 292,
86b8e80941Smrg    STRUCT = 293,
87b8e80941Smrg    VOID_TOK = 294,
88b8e80941Smrg    WHILE = 295,
89b8e80941Smrg    IDENTIFIER = 296,
90b8e80941Smrg    TYPE_IDENTIFIER = 297,
91b8e80941Smrg    NEW_IDENTIFIER = 298,
92b8e80941Smrg    FLOATCONSTANT = 299,
93b8e80941Smrg    DOUBLECONSTANT = 300,
94b8e80941Smrg    INTCONSTANT = 301,
95b8e80941Smrg    UINTCONSTANT = 302,
96b8e80941Smrg    BOOLCONSTANT = 303,
97b8e80941Smrg    INT64CONSTANT = 304,
98b8e80941Smrg    UINT64CONSTANT = 305,
99b8e80941Smrg    FIELD_SELECTION = 306,
100b8e80941Smrg    LEFT_OP = 307,
101b8e80941Smrg    RIGHT_OP = 308,
102b8e80941Smrg    INC_OP = 309,
103b8e80941Smrg    DEC_OP = 310,
104b8e80941Smrg    LE_OP = 311,
105b8e80941Smrg    GE_OP = 312,
106b8e80941Smrg    EQ_OP = 313,
107b8e80941Smrg    NE_OP = 314,
108b8e80941Smrg    AND_OP = 315,
109b8e80941Smrg    OR_OP = 316,
110b8e80941Smrg    XOR_OP = 317,
111b8e80941Smrg    MUL_ASSIGN = 318,
112b8e80941Smrg    DIV_ASSIGN = 319,
113b8e80941Smrg    ADD_ASSIGN = 320,
114b8e80941Smrg    MOD_ASSIGN = 321,
115b8e80941Smrg    LEFT_ASSIGN = 322,
116b8e80941Smrg    RIGHT_ASSIGN = 323,
117b8e80941Smrg    AND_ASSIGN = 324,
118b8e80941Smrg    XOR_ASSIGN = 325,
119b8e80941Smrg    OR_ASSIGN = 326,
120b8e80941Smrg    SUB_ASSIGN = 327,
121b8e80941Smrg    INVARIANT = 328,
122b8e80941Smrg    PRECISE = 329,
123b8e80941Smrg    LOWP = 330,
124b8e80941Smrg    MEDIUMP = 331,
125b8e80941Smrg    HIGHP = 332,
126b8e80941Smrg    SUPERP = 333,
127b8e80941Smrg    PRECISION = 334,
128b8e80941Smrg    VERSION_TOK = 335,
129b8e80941Smrg    EXTENSION = 336,
130b8e80941Smrg    LINE = 337,
131b8e80941Smrg    COLON = 338,
132b8e80941Smrg    EOL = 339,
133b8e80941Smrg    INTERFACE = 340,
134b8e80941Smrg    OUTPUT = 341,
135b8e80941Smrg    PRAGMA_DEBUG_ON = 342,
136b8e80941Smrg    PRAGMA_DEBUG_OFF = 343,
137b8e80941Smrg    PRAGMA_OPTIMIZE_ON = 344,
138b8e80941Smrg    PRAGMA_OPTIMIZE_OFF = 345,
139b8e80941Smrg    PRAGMA_WARNING_ON = 346,
140b8e80941Smrg    PRAGMA_WARNING_OFF = 347,
141b8e80941Smrg    PRAGMA_INVARIANT_ALL = 348,
142b8e80941Smrg    LAYOUT_TOK = 349,
143b8e80941Smrg    DOT_TOK = 350,
144b8e80941Smrg    ASM = 351,
145b8e80941Smrg    CLASS = 352,
146b8e80941Smrg    UNION = 353,
147b8e80941Smrg    ENUM = 354,
148b8e80941Smrg    TYPEDEF = 355,
149b8e80941Smrg    TEMPLATE = 356,
150b8e80941Smrg    THIS = 357,
151b8e80941Smrg    PACKED_TOK = 358,
152b8e80941Smrg    GOTO = 359,
153b8e80941Smrg    INLINE_TOK = 360,
154b8e80941Smrg    NOINLINE = 361,
155b8e80941Smrg    PUBLIC_TOK = 362,
156b8e80941Smrg    STATIC = 363,
157b8e80941Smrg    EXTERN = 364,
158b8e80941Smrg    EXTERNAL = 365,
159b8e80941Smrg    LONG_TOK = 366,
160b8e80941Smrg    SHORT_TOK = 367,
161b8e80941Smrg    HALF = 368,
162b8e80941Smrg    FIXED_TOK = 369,
163b8e80941Smrg    UNSIGNED = 370,
164b8e80941Smrg    INPUT_TOK = 371,
165b8e80941Smrg    HVEC2 = 372,
166b8e80941Smrg    HVEC3 = 373,
167b8e80941Smrg    HVEC4 = 374,
168b8e80941Smrg    FVEC2 = 375,
169b8e80941Smrg    FVEC3 = 376,
170b8e80941Smrg    FVEC4 = 377,
171b8e80941Smrg    SAMPLER3DRECT = 378,
172b8e80941Smrg    SIZEOF = 379,
173b8e80941Smrg    CAST = 380,
174b8e80941Smrg    NAMESPACE = 381,
175b8e80941Smrg    USING = 382,
176b8e80941Smrg    RESOURCE = 383,
177b8e80941Smrg    PATCH = 384,
178b8e80941Smrg    SUBROUTINE = 385,
179b8e80941Smrg    ERROR_TOK = 386,
180b8e80941Smrg    COMMON = 387,
181b8e80941Smrg    PARTITION = 388,
182b8e80941Smrg    ACTIVE = 389,
183b8e80941Smrg    FILTER = 390,
184b8e80941Smrg    ROW_MAJOR = 391,
185b8e80941Smrg    THEN = 392
186b8e80941Smrg  };
187b8e80941Smrg#endif
188b8e80941Smrg
189b8e80941Smrg/* Value type.  */
190b8e80941Smrg#if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED
191b8e80941Smrg
192b8e80941Smrgunion YYSTYPE
193b8e80941Smrg{
194b8e80941Smrg#line 98 "../src/compiler/glsl/glsl_parser.yy" /* yacc.c:1906  */
195b8e80941Smrg
196b8e80941Smrg   int n;
197b8e80941Smrg   int64_t n64;
198b8e80941Smrg   float real;
199b8e80941Smrg   double dreal;
200b8e80941Smrg   const char *identifier;
201b8e80941Smrg
202b8e80941Smrg   struct ast_type_qualifier type_qualifier;
203b8e80941Smrg
204b8e80941Smrg   ast_node *node;
205b8e80941Smrg   ast_type_specifier *type_specifier;
206b8e80941Smrg   ast_array_specifier *array_specifier;
207b8e80941Smrg   ast_fully_specified_type *fully_specified_type;
208b8e80941Smrg   ast_function *function;
209b8e80941Smrg   ast_parameter_declarator *parameter_declarator;
210b8e80941Smrg   ast_function_definition *function_definition;
211b8e80941Smrg   ast_compound_statement *compound_statement;
212b8e80941Smrg   ast_expression *expression;
213b8e80941Smrg   ast_declarator_list *declarator_list;
214b8e80941Smrg   ast_struct_specifier *struct_specifier;
215b8e80941Smrg   ast_declaration *declaration;
216b8e80941Smrg   ast_switch_body *switch_body;
217b8e80941Smrg   ast_case_label *case_label;
218b8e80941Smrg   ast_case_label_list *case_label_list;
219b8e80941Smrg   ast_case_statement *case_statement;
220b8e80941Smrg   ast_case_statement_list *case_statement_list;
221b8e80941Smrg   ast_interface_block *interface_block;
222b8e80941Smrg   ast_subroutine_list *subroutine_list;
223b8e80941Smrg   struct {
224b8e80941Smrg      ast_node *cond;
225b8e80941Smrg      ast_expression *rest;
226b8e80941Smrg   } for_rest_statement;
227b8e80941Smrg
228b8e80941Smrg   struct {
229b8e80941Smrg      ast_node *then_statement;
230b8e80941Smrg      ast_node *else_statement;
231b8e80941Smrg   } selection_rest_statement;
232b8e80941Smrg
233b8e80941Smrg   const glsl_type *type;
234b8e80941Smrg
235b8e80941Smrg#line 236 "src/compiler/glsl/glsl_parser.h" /* yacc.c:1906  */
236b8e80941Smrg};
237b8e80941Smrg
238b8e80941Smrgtypedef union YYSTYPE YYSTYPE;
239b8e80941Smrg# define YYSTYPE_IS_TRIVIAL 1
240b8e80941Smrg# define YYSTYPE_IS_DECLARED 1
241b8e80941Smrg#endif
242b8e80941Smrg
243b8e80941Smrg/* Location type.  */
244b8e80941Smrg#if ! defined YYLTYPE && ! defined YYLTYPE_IS_DECLARED
245b8e80941Smrgtypedef struct YYLTYPE YYLTYPE;
246b8e80941Smrgstruct YYLTYPE
247b8e80941Smrg{
248b8e80941Smrg  int first_line;
249b8e80941Smrg  int first_column;
250b8e80941Smrg  int last_line;
251b8e80941Smrg  int last_column;
252b8e80941Smrg};
253b8e80941Smrg# define YYLTYPE_IS_DECLARED 1
254b8e80941Smrg# define YYLTYPE_IS_TRIVIAL 1
255b8e80941Smrg#endif
256b8e80941Smrg
257b8e80941Smrg
258b8e80941Smrg
259b8e80941Smrgint _mesa_glsl_parse (struct _mesa_glsl_parse_state *state);
260b8e80941Smrg
261b8e80941Smrg#endif /* !YY__MESA_GLSL_SRC_COMPILER_GLSL_GLSL_PARSER_H_INCLUDED  */
262