Home | History | Annotate | Download | only in compiler
      1 /* A Bison parser, made by GNU Bison 2.7.  */
      2 
      3 /* Bison interface for Yacc-like parsers in C
      4 
      5       Copyright (C) 1984, 1989-1990, 2000-2012 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_YY_GLSLANG_TAB_H_INCLUDED
     34 # define YY_YY_GLSLANG_TAB_H_INCLUDED
     35 /* Enabling traces.  */
     36 #ifndef YYDEBUG
     37 # define YYDEBUG 0
     38 #endif
     39 #if YYDEBUG
     40 extern int yydebug;
     41 #endif
     42 /* "%code requires" blocks.  */
     43 
     44 
     45 #define YYLTYPE TSourceLoc
     46 #define YYLTYPE_IS_DECLARED 1
     47 #define SH_MAX_TOKEN_LENGTH 256  // WebGL spec.
     48 
     49 
     50 
     51 
     52 /* Tokens.  */
     53 #ifndef YYTOKENTYPE
     54 # define YYTOKENTYPE
     55    /* Put the tokens into the symbol table, so that GDB and other debuggers
     56       know about them.  */
     57    enum yytokentype {
     58      INVARIANT = 258,
     59      HIGH_PRECISION = 259,
     60      MEDIUM_PRECISION = 260,
     61      LOW_PRECISION = 261,
     62      PRECISION = 262,
     63      ATTRIBUTE = 263,
     64      CONST_QUAL = 264,
     65      BOOL_TYPE = 265,
     66      FLOAT_TYPE = 266,
     67      INT_TYPE = 267,
     68      BREAK = 268,
     69      CONTINUE = 269,
     70      DO = 270,
     71      ELSE = 271,
     72      FOR = 272,
     73      IF = 273,
     74      DISCARD = 274,
     75      RETURN = 275,
     76      BVEC2 = 276,
     77      BVEC3 = 277,
     78      BVEC4 = 278,
     79      IVEC2 = 279,
     80      IVEC3 = 280,
     81      IVEC4 = 281,
     82      VEC2 = 282,
     83      VEC3 = 283,
     84      VEC4 = 284,
     85      MATRIX2 = 285,
     86      MATRIX3 = 286,
     87      MATRIX4 = 287,
     88      IN_QUAL = 288,
     89      OUT_QUAL = 289,
     90      INOUT_QUAL = 290,
     91      UNIFORM = 291,
     92      VARYING = 292,
     93      STRUCT = 293,
     94      VOID_TYPE = 294,
     95      WHILE = 295,
     96      SAMPLER2D = 296,
     97      SAMPLERCUBE = 297,
     98      SAMPLER_EXTERNAL_OES = 298,
     99      SAMPLER2DRECT = 299,
    100      IDENTIFIER = 300,
    101      TYPE_NAME = 301,
    102      FLOATCONSTANT = 302,
    103      INTCONSTANT = 303,
    104      BOOLCONSTANT = 304,
    105      LEFT_OP = 305,
    106      RIGHT_OP = 306,
    107      INC_OP = 307,
    108      DEC_OP = 308,
    109      LE_OP = 309,
    110      GE_OP = 310,
    111      EQ_OP = 311,
    112      NE_OP = 312,
    113      AND_OP = 313,
    114      OR_OP = 314,
    115      XOR_OP = 315,
    116      MUL_ASSIGN = 316,
    117      DIV_ASSIGN = 317,
    118      ADD_ASSIGN = 318,
    119      MOD_ASSIGN = 319,
    120      LEFT_ASSIGN = 320,
    121      RIGHT_ASSIGN = 321,
    122      AND_ASSIGN = 322,
    123      XOR_ASSIGN = 323,
    124      OR_ASSIGN = 324,
    125      SUB_ASSIGN = 325,
    126      LEFT_PAREN = 326,
    127      RIGHT_PAREN = 327,
    128      LEFT_BRACKET = 328,
    129      RIGHT_BRACKET = 329,
    130      LEFT_BRACE = 330,
    131      RIGHT_BRACE = 331,
    132      DOT = 332,
    133      COMMA = 333,
    134      COLON = 334,
    135      EQUAL = 335,
    136      SEMICOLON = 336,
    137      BANG = 337,
    138      DASH = 338,
    139      TILDE = 339,
    140      PLUS = 340,
    141      STAR = 341,
    142      SLASH = 342,
    143      PERCENT = 343,
    144      LEFT_ANGLE = 344,
    145      RIGHT_ANGLE = 345,
    146      VERTICAL_BAR = 346,
    147      CARET = 347,
    148      AMPERSAND = 348,
    149      QUESTION = 349
    150    };
    151 #endif
    152 
    153 
    154 #if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED
    155 typedef union YYSTYPE
    156 {
    157 
    158 
    159     struct {
    160         union {
    161             TString *string;
    162             float f;
    163             int i;
    164             bool b;
    165         };
    166         TSymbol* symbol;
    167     } lex;
    168     struct {
    169         TOperator op;
    170         union {
    171             TIntermNode* intermNode;
    172             TIntermNodePair nodePair;
    173             TIntermTyped* intermTypedNode;
    174             TIntermAggregate* intermAggregate;
    175         };
    176         union {
    177             TPublicType type;
    178             TPrecision precision;
    179             TQualifier qualifier;
    180             TFunction* function;
    181             TParameter param;
    182             TField* field;
    183             TFieldList* fieldList;
    184         };
    185     } interm;
    186 
    187 
    188 
    189 } YYSTYPE;
    190 # define YYSTYPE_IS_TRIVIAL 1
    191 # define yystype YYSTYPE /* obsolescent; will be withdrawn */
    192 # define YYSTYPE_IS_DECLARED 1
    193 #endif
    194 
    195 #if ! defined YYLTYPE && ! defined YYLTYPE_IS_DECLARED
    196 typedef struct YYLTYPE
    197 {
    198   int first_line;
    199   int first_column;
    200   int last_line;
    201   int last_column;
    202 } YYLTYPE;
    203 # define yyltype YYLTYPE /* obsolescent; will be withdrawn */
    204 # define YYLTYPE_IS_DECLARED 1
    205 # define YYLTYPE_IS_TRIVIAL 1
    206 #endif
    207 
    208 
    209 #ifdef YYPARSE_PARAM
    210 #if defined __STDC__ || defined __cplusplus
    211 int yyparse (void *YYPARSE_PARAM);
    212 #else
    213 int yyparse ();
    214 #endif
    215 #else /* ! YYPARSE_PARAM */
    216 #if defined __STDC__ || defined __cplusplus
    217 int yyparse (TParseContext* context);
    218 #else
    219 int yyparse ();
    220 #endif
    221 #endif /* ! YYPARSE_PARAM */
    222 
    223 #endif /* !YY_YY_GLSLANG_TAB_H_INCLUDED  */
    224