gfx/angle/src/compiler/glslang_tab.cpp

changeset 0
6474c204b198
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/gfx/angle/src/compiler/glslang_tab.cpp	Wed Dec 31 06:09:35 2014 +0100
     1.3 @@ -0,0 +1,4882 @@
     1.4 +/* A Bison parser, made by GNU Bison 2.7.  */
     1.5 +
     1.6 +/* Bison implementation for Yacc-like parsers in C
     1.7 +   
     1.8 +      Copyright (C) 1984, 1989-1990, 2000-2012 Free Software Foundation, Inc.
     1.9 +   
    1.10 +   This program is free software: you can redistribute it and/or modify
    1.11 +   it under the terms of the GNU General Public License as published by
    1.12 +   the Free Software Foundation, either version 3 of the License, or
    1.13 +   (at your option) any later version.
    1.14 +   
    1.15 +   This program is distributed in the hope that it will be useful,
    1.16 +   but WITHOUT ANY WARRANTY; without even the implied warranty of
    1.17 +   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
    1.18 +   GNU General Public License for more details.
    1.19 +   
    1.20 +   You should have received a copy of the GNU General Public License
    1.21 +   along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
    1.22 +
    1.23 +/* As a special exception, you may create a larger work that contains
    1.24 +   part or all of the Bison parser skeleton and distribute that work
    1.25 +   under terms of your choice, so long as that work isn't itself a
    1.26 +   parser generator using the skeleton or a modified version thereof
    1.27 +   as a parser skeleton.  Alternatively, if you modify or redistribute
    1.28 +   the parser skeleton itself, you may (at your option) remove this
    1.29 +   special exception, which will cause the skeleton and the resulting
    1.30 +   Bison output files to be licensed under the GNU General Public
    1.31 +   License without this special exception.
    1.32 +   
    1.33 +   This special exception was added by the Free Software Foundation in
    1.34 +   version 2.2 of Bison.  */
    1.35 +
    1.36 +/* C LALR(1) parser skeleton written by Richard Stallman, by
    1.37 +   simplifying the original so-called "semantic" parser.  */
    1.38 +
    1.39 +/* All symbols defined below should begin with yy or YY, to avoid
    1.40 +   infringing on user name space.  This should be done even for local
    1.41 +   variables, as they might otherwise be expanded by user macros.
    1.42 +   There are some unavoidable exceptions within include files to
    1.43 +   define necessary library symbols; they are noted "INFRINGES ON
    1.44 +   USER NAME SPACE" below.  */
    1.45 +
    1.46 +/* Identify Bison output.  */
    1.47 +#define YYBISON 1
    1.48 +
    1.49 +/* Bison version.  */
    1.50 +#define YYBISON_VERSION "2.7"
    1.51 +
    1.52 +/* Skeleton name.  */
    1.53 +#define YYSKELETON_NAME "yacc.c"
    1.54 +
    1.55 +/* Pure parsers.  */
    1.56 +#define YYPURE 1
    1.57 +
    1.58 +/* Push parsers.  */
    1.59 +#define YYPUSH 0
    1.60 +
    1.61 +/* Pull parsers.  */
    1.62 +#define YYPULL 1
    1.63 +
    1.64 +
    1.65 +
    1.66 +
    1.67 +/* Copy the first part of user declarations.  */
    1.68 +
    1.69 +
    1.70 +//
    1.71 +// Copyright (c) 2002-2010 The ANGLE Project Authors. All rights reserved.
    1.72 +// Use of this source code is governed by a BSD-style license that can be
    1.73 +// found in the LICENSE file.
    1.74 +//
    1.75 +
    1.76 +// This file is auto-generated by generate_parser.sh. DO NOT EDIT!
    1.77 +
    1.78 +// Ignore errors in auto-generated code.
    1.79 +#if defined(__GNUC__)
    1.80 +#pragma GCC diagnostic ignored "-Wunused-function"
    1.81 +#pragma GCC diagnostic ignored "-Wunused-variable"
    1.82 +#pragma GCC diagnostic ignored "-Wswitch-enum"
    1.83 +#elif defined(_MSC_VER)
    1.84 +#pragma warning(disable: 4065)
    1.85 +#pragma warning(disable: 4189)
    1.86 +#pragma warning(disable: 4505)
    1.87 +#pragma warning(disable: 4701)
    1.88 +#endif
    1.89 +
    1.90 +#include "compiler/SymbolTable.h"
    1.91 +#include "compiler/ParseHelper.h"
    1.92 +#include "GLSLANG/ShaderLang.h"
    1.93 +
    1.94 +#define YYENABLE_NLS 0
    1.95 +
    1.96 +#define YYLEX_PARAM context->scanner
    1.97 +
    1.98 +
    1.99 +
   1.100 +# ifndef YY_NULL
   1.101 +#  if defined __cplusplus && 201103L <= __cplusplus
   1.102 +#   define YY_NULL nullptr
   1.103 +#  else
   1.104 +#   define YY_NULL 0
   1.105 +#  endif
   1.106 +# endif
   1.107 +
   1.108 +/* Enabling verbose error messages.  */
   1.109 +#ifdef YYERROR_VERBOSE
   1.110 +# undef YYERROR_VERBOSE
   1.111 +# define YYERROR_VERBOSE 1
   1.112 +#else
   1.113 +# define YYERROR_VERBOSE 0
   1.114 +#endif
   1.115 +
   1.116 +/* In a future release of Bison, this section will be replaced
   1.117 +   by #include "glslang_tab.h".  */
   1.118 +#ifndef YY_YY_GLSLANG_TAB_H_INCLUDED
   1.119 +# define YY_YY_GLSLANG_TAB_H_INCLUDED
   1.120 +/* Enabling traces.  */
   1.121 +#ifndef YYDEBUG
   1.122 +# define YYDEBUG 0
   1.123 +#endif
   1.124 +#if YYDEBUG
   1.125 +extern int yydebug;
   1.126 +#endif
   1.127 +/* "%code requires" blocks.  */
   1.128 +
   1.129 +
   1.130 +#define YYLTYPE TSourceLoc
   1.131 +#define YYLTYPE_IS_DECLARED 1
   1.132 +
   1.133 +
   1.134 +
   1.135 +
   1.136 +/* Tokens.  */
   1.137 +#ifndef YYTOKENTYPE
   1.138 +# define YYTOKENTYPE
   1.139 +   /* Put the tokens into the symbol table, so that GDB and other debuggers
   1.140 +      know about them.  */
   1.141 +   enum yytokentype {
   1.142 +     INVARIANT = 258,
   1.143 +     HIGH_PRECISION = 259,
   1.144 +     MEDIUM_PRECISION = 260,
   1.145 +     LOW_PRECISION = 261,
   1.146 +     PRECISION = 262,
   1.147 +     ATTRIBUTE = 263,
   1.148 +     CONST_QUAL = 264,
   1.149 +     BOOL_TYPE = 265,
   1.150 +     FLOAT_TYPE = 266,
   1.151 +     INT_TYPE = 267,
   1.152 +     BREAK = 268,
   1.153 +     CONTINUE = 269,
   1.154 +     DO = 270,
   1.155 +     ELSE = 271,
   1.156 +     FOR = 272,
   1.157 +     IF = 273,
   1.158 +     DISCARD = 274,
   1.159 +     RETURN = 275,
   1.160 +     BVEC2 = 276,
   1.161 +     BVEC3 = 277,
   1.162 +     BVEC4 = 278,
   1.163 +     IVEC2 = 279,
   1.164 +     IVEC3 = 280,
   1.165 +     IVEC4 = 281,
   1.166 +     VEC2 = 282,
   1.167 +     VEC3 = 283,
   1.168 +     VEC4 = 284,
   1.169 +     MATRIX2 = 285,
   1.170 +     MATRIX3 = 286,
   1.171 +     MATRIX4 = 287,
   1.172 +     IN_QUAL = 288,
   1.173 +     OUT_QUAL = 289,
   1.174 +     INOUT_QUAL = 290,
   1.175 +     UNIFORM = 291,
   1.176 +     VARYING = 292,
   1.177 +     STRUCT = 293,
   1.178 +     VOID_TYPE = 294,
   1.179 +     WHILE = 295,
   1.180 +     SAMPLER2D = 296,
   1.181 +     SAMPLERCUBE = 297,
   1.182 +     SAMPLER_EXTERNAL_OES = 298,
   1.183 +     SAMPLER2DRECT = 299,
   1.184 +     IDENTIFIER = 300,
   1.185 +     TYPE_NAME = 301,
   1.186 +     FLOATCONSTANT = 302,
   1.187 +     INTCONSTANT = 303,
   1.188 +     BOOLCONSTANT = 304,
   1.189 +     LEFT_OP = 305,
   1.190 +     RIGHT_OP = 306,
   1.191 +     INC_OP = 307,
   1.192 +     DEC_OP = 308,
   1.193 +     LE_OP = 309,
   1.194 +     GE_OP = 310,
   1.195 +     EQ_OP = 311,
   1.196 +     NE_OP = 312,
   1.197 +     AND_OP = 313,
   1.198 +     OR_OP = 314,
   1.199 +     XOR_OP = 315,
   1.200 +     MUL_ASSIGN = 316,
   1.201 +     DIV_ASSIGN = 317,
   1.202 +     ADD_ASSIGN = 318,
   1.203 +     MOD_ASSIGN = 319,
   1.204 +     LEFT_ASSIGN = 320,
   1.205 +     RIGHT_ASSIGN = 321,
   1.206 +     AND_ASSIGN = 322,
   1.207 +     XOR_ASSIGN = 323,
   1.208 +     OR_ASSIGN = 324,
   1.209 +     SUB_ASSIGN = 325,
   1.210 +     LEFT_PAREN = 326,
   1.211 +     RIGHT_PAREN = 327,
   1.212 +     LEFT_BRACKET = 328,
   1.213 +     RIGHT_BRACKET = 329,
   1.214 +     LEFT_BRACE = 330,
   1.215 +     RIGHT_BRACE = 331,
   1.216 +     DOT = 332,
   1.217 +     COMMA = 333,
   1.218 +     COLON = 334,
   1.219 +     EQUAL = 335,
   1.220 +     SEMICOLON = 336,
   1.221 +     BANG = 337,
   1.222 +     DASH = 338,
   1.223 +     TILDE = 339,
   1.224 +     PLUS = 340,
   1.225 +     STAR = 341,
   1.226 +     SLASH = 342,
   1.227 +     PERCENT = 343,
   1.228 +     LEFT_ANGLE = 344,
   1.229 +     RIGHT_ANGLE = 345,
   1.230 +     VERTICAL_BAR = 346,
   1.231 +     CARET = 347,
   1.232 +     AMPERSAND = 348,
   1.233 +     QUESTION = 349
   1.234 +   };
   1.235 +#endif
   1.236 +
   1.237 +
   1.238 +#if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED
   1.239 +typedef union YYSTYPE
   1.240 +{
   1.241 +
   1.242 +
   1.243 +    struct {
   1.244 +        union {
   1.245 +            TString *string;
   1.246 +            float f;
   1.247 +            int i;
   1.248 +            bool b;
   1.249 +        };
   1.250 +        TSymbol* symbol;
   1.251 +    } lex;
   1.252 +    struct {
   1.253 +        TOperator op;
   1.254 +        union {
   1.255 +            TIntermNode* intermNode;
   1.256 +            TIntermNodePair nodePair;
   1.257 +            TIntermTyped* intermTypedNode;
   1.258 +            TIntermAggregate* intermAggregate;
   1.259 +        };
   1.260 +        union {
   1.261 +            TPublicType type;
   1.262 +            TPrecision precision;
   1.263 +            TQualifier qualifier;
   1.264 +            TFunction* function;
   1.265 +            TParameter param;
   1.266 +            TField* field;
   1.267 +            TFieldList* fieldList;
   1.268 +        };
   1.269 +    } interm;
   1.270 +
   1.271 +
   1.272 +
   1.273 +} YYSTYPE;
   1.274 +# define YYSTYPE_IS_TRIVIAL 1
   1.275 +# define yystype YYSTYPE /* obsolescent; will be withdrawn */
   1.276 +# define YYSTYPE_IS_DECLARED 1
   1.277 +#endif
   1.278 +
   1.279 +#if ! defined YYLTYPE && ! defined YYLTYPE_IS_DECLARED
   1.280 +typedef struct YYLTYPE
   1.281 +{
   1.282 +  int first_line;
   1.283 +  int first_column;
   1.284 +  int last_line;
   1.285 +  int last_column;
   1.286 +} YYLTYPE;
   1.287 +# define yyltype YYLTYPE /* obsolescent; will be withdrawn */
   1.288 +# define YYLTYPE_IS_DECLARED 1
   1.289 +# define YYLTYPE_IS_TRIVIAL 1
   1.290 +#endif
   1.291 +
   1.292 +
   1.293 +#ifdef YYPARSE_PARAM
   1.294 +#if defined __STDC__ || defined __cplusplus
   1.295 +int yyparse (void *YYPARSE_PARAM);
   1.296 +#else
   1.297 +int yyparse ();
   1.298 +#endif
   1.299 +#else /* ! YYPARSE_PARAM */
   1.300 +#if defined __STDC__ || defined __cplusplus
   1.301 +int yyparse (TParseContext* context);
   1.302 +#else
   1.303 +int yyparse ();
   1.304 +#endif
   1.305 +#endif /* ! YYPARSE_PARAM */
   1.306 +
   1.307 +#endif /* !YY_YY_GLSLANG_TAB_H_INCLUDED  */
   1.308 +
   1.309 +/* Copy the second part of user declarations.  */
   1.310 +
   1.311 +
   1.312 +extern int yylex(YYSTYPE* yylval, YYLTYPE* yylloc, void* yyscanner);
   1.313 +static void yyerror(YYLTYPE* yylloc, TParseContext* context, const char* reason);
   1.314 +
   1.315 +#define YYLLOC_DEFAULT(Current, Rhs, N)                      \
   1.316 +  do {                                                       \
   1.317 +      if (YYID(N)) {                                         \
   1.318 +        (Current).first_file = YYRHSLOC(Rhs, 1).first_file;  \
   1.319 +        (Current).first_line = YYRHSLOC(Rhs, 1).first_line;  \
   1.320 +        (Current).last_file = YYRHSLOC(Rhs, N).last_file;    \
   1.321 +        (Current).last_line = YYRHSLOC(Rhs, N).last_line;    \
   1.322 +      }                                                      \
   1.323 +      else {                                                 \
   1.324 +        (Current).first_file = YYRHSLOC(Rhs, 0).last_file;   \
   1.325 +        (Current).first_line = YYRHSLOC(Rhs, 0).last_line;   \
   1.326 +        (Current).last_file = YYRHSLOC(Rhs, 0).last_file;    \
   1.327 +        (Current).last_line = YYRHSLOC(Rhs, 0).last_line;    \
   1.328 +      }                                                      \
   1.329 +  } while (0)
   1.330 +
   1.331 +#define VERTEX_ONLY(S, L) {  \
   1.332 +    if (context->shaderType != SH_VERTEX_SHADER) {  \
   1.333 +        context->error(L, " supported in vertex shaders only ", S);  \
   1.334 +        context->recover();  \
   1.335 +    }  \
   1.336 +}
   1.337 +
   1.338 +#define FRAG_ONLY(S, L) {  \
   1.339 +    if (context->shaderType != SH_FRAGMENT_SHADER) {  \
   1.340 +        context->error(L, " supported in fragment shaders only ", S);  \
   1.341 +        context->recover();  \
   1.342 +    }  \
   1.343 +}
   1.344 +
   1.345 +
   1.346 +
   1.347 +#ifdef short
   1.348 +# undef short
   1.349 +#endif
   1.350 +
   1.351 +#ifdef YYTYPE_UINT8
   1.352 +typedef YYTYPE_UINT8 yytype_uint8;
   1.353 +#else
   1.354 +typedef unsigned char yytype_uint8;
   1.355 +#endif
   1.356 +
   1.357 +#ifdef YYTYPE_INT8
   1.358 +typedef YYTYPE_INT8 yytype_int8;
   1.359 +#elif (defined __STDC__ || defined __C99__FUNC__ \
   1.360 +     || defined __cplusplus || defined _MSC_VER)
   1.361 +typedef signed char yytype_int8;
   1.362 +#else
   1.363 +typedef short int yytype_int8;
   1.364 +#endif
   1.365 +
   1.366 +#ifdef YYTYPE_UINT16
   1.367 +typedef YYTYPE_UINT16 yytype_uint16;
   1.368 +#else
   1.369 +typedef unsigned short int yytype_uint16;
   1.370 +#endif
   1.371 +
   1.372 +#ifdef YYTYPE_INT16
   1.373 +typedef YYTYPE_INT16 yytype_int16;
   1.374 +#else
   1.375 +typedef short int yytype_int16;
   1.376 +#endif
   1.377 +
   1.378 +#ifndef YYSIZE_T
   1.379 +# ifdef __SIZE_TYPE__
   1.380 +#  define YYSIZE_T __SIZE_TYPE__
   1.381 +# elif defined size_t
   1.382 +#  define YYSIZE_T size_t
   1.383 +# elif ! defined YYSIZE_T && (defined __STDC__ || defined __C99__FUNC__ \
   1.384 +     || defined __cplusplus || defined _MSC_VER)
   1.385 +#  include <stddef.h> /* INFRINGES ON USER NAME SPACE */
   1.386 +#  define YYSIZE_T size_t
   1.387 +# else
   1.388 +#  define YYSIZE_T unsigned int
   1.389 +# endif
   1.390 +#endif
   1.391 +
   1.392 +#define YYSIZE_MAXIMUM ((YYSIZE_T) -1)
   1.393 +
   1.394 +#ifndef YY_
   1.395 +# if defined YYENABLE_NLS && YYENABLE_NLS
   1.396 +#  if ENABLE_NLS
   1.397 +#   include <libintl.h> /* INFRINGES ON USER NAME SPACE */
   1.398 +#   define YY_(Msgid) dgettext ("bison-runtime", Msgid)
   1.399 +#  endif
   1.400 +# endif
   1.401 +# ifndef YY_
   1.402 +#  define YY_(Msgid) Msgid
   1.403 +# endif
   1.404 +#endif
   1.405 +
   1.406 +/* Suppress unused-variable warnings by "using" E.  */
   1.407 +#if ! defined lint || defined __GNUC__
   1.408 +# define YYUSE(E) ((void) (E))
   1.409 +#else
   1.410 +# define YYUSE(E) /* empty */
   1.411 +#endif
   1.412 +
   1.413 +/* Identity function, used to suppress warnings about constant conditions.  */
   1.414 +#ifndef lint
   1.415 +# define YYID(N) (N)
   1.416 +#else
   1.417 +#if (defined __STDC__ || defined __C99__FUNC__ \
   1.418 +     || defined __cplusplus || defined _MSC_VER)
   1.419 +static int
   1.420 +YYID (int yyi)
   1.421 +#else
   1.422 +static int
   1.423 +YYID (yyi)
   1.424 +    int yyi;
   1.425 +#endif
   1.426 +{
   1.427 +  return yyi;
   1.428 +}
   1.429 +#endif
   1.430 +
   1.431 +#if ! defined yyoverflow || YYERROR_VERBOSE
   1.432 +
   1.433 +/* The parser invokes alloca or malloc; define the necessary symbols.  */
   1.434 +
   1.435 +# ifdef YYSTACK_USE_ALLOCA
   1.436 +#  if YYSTACK_USE_ALLOCA
   1.437 +#   ifdef __GNUC__
   1.438 +#    define YYSTACK_ALLOC __builtin_alloca
   1.439 +#   elif defined __BUILTIN_VA_ARG_INCR
   1.440 +#    include <alloca.h> /* INFRINGES ON USER NAME SPACE */
   1.441 +#   elif defined _AIX
   1.442 +#    define YYSTACK_ALLOC __alloca
   1.443 +#   elif defined _MSC_VER
   1.444 +#    include <malloc.h> /* INFRINGES ON USER NAME SPACE */
   1.445 +#    define alloca _alloca
   1.446 +#   else
   1.447 +#    define YYSTACK_ALLOC alloca
   1.448 +#    if ! defined _ALLOCA_H && ! defined EXIT_SUCCESS && (defined __STDC__ || defined __C99__FUNC__ \
   1.449 +     || defined __cplusplus || defined _MSC_VER)
   1.450 +#     include <stdlib.h> /* INFRINGES ON USER NAME SPACE */
   1.451 +      /* Use EXIT_SUCCESS as a witness for stdlib.h.  */
   1.452 +#     ifndef EXIT_SUCCESS
   1.453 +#      define EXIT_SUCCESS 0
   1.454 +#     endif
   1.455 +#    endif
   1.456 +#   endif
   1.457 +#  endif
   1.458 +# endif
   1.459 +
   1.460 +# ifdef YYSTACK_ALLOC
   1.461 +   /* Pacify GCC's `empty if-body' warning.  */
   1.462 +#  define YYSTACK_FREE(Ptr) do { /* empty */; } while (YYID (0))
   1.463 +#  ifndef YYSTACK_ALLOC_MAXIMUM
   1.464 +    /* The OS might guarantee only one guard page at the bottom of the stack,
   1.465 +       and a page size can be as small as 4096 bytes.  So we cannot safely
   1.466 +       invoke alloca (N) if N exceeds 4096.  Use a slightly smaller number
   1.467 +       to allow for a few compiler-allocated temporary stack slots.  */
   1.468 +#   define YYSTACK_ALLOC_MAXIMUM 4032 /* reasonable circa 2006 */
   1.469 +#  endif
   1.470 +# else
   1.471 +#  define YYSTACK_ALLOC YYMALLOC
   1.472 +#  define YYSTACK_FREE YYFREE
   1.473 +#  ifndef YYSTACK_ALLOC_MAXIMUM
   1.474 +#   define YYSTACK_ALLOC_MAXIMUM YYSIZE_MAXIMUM
   1.475 +#  endif
   1.476 +#  if (defined __cplusplus && ! defined EXIT_SUCCESS \
   1.477 +       && ! ((defined YYMALLOC || defined malloc) \
   1.478 +	     && (defined YYFREE || defined free)))
   1.479 +#   include <stdlib.h> /* INFRINGES ON USER NAME SPACE */
   1.480 +#   ifndef EXIT_SUCCESS
   1.481 +#    define EXIT_SUCCESS 0
   1.482 +#   endif
   1.483 +#  endif
   1.484 +#  ifndef YYMALLOC
   1.485 +#   define YYMALLOC malloc
   1.486 +#   if ! defined malloc && ! defined EXIT_SUCCESS && (defined __STDC__ || defined __C99__FUNC__ \
   1.487 +     || defined __cplusplus || defined _MSC_VER)
   1.488 +void *malloc (YYSIZE_T); /* INFRINGES ON USER NAME SPACE */
   1.489 +#   endif
   1.490 +#  endif
   1.491 +#  ifndef YYFREE
   1.492 +#   define YYFREE free
   1.493 +#   if ! defined free && ! defined EXIT_SUCCESS && (defined __STDC__ || defined __C99__FUNC__ \
   1.494 +     || defined __cplusplus || defined _MSC_VER)
   1.495 +void free (void *); /* INFRINGES ON USER NAME SPACE */
   1.496 +#   endif
   1.497 +#  endif
   1.498 +# endif
   1.499 +#endif /* ! defined yyoverflow || YYERROR_VERBOSE */
   1.500 +
   1.501 +
   1.502 +#if (! defined yyoverflow \
   1.503 +     && (! defined __cplusplus \
   1.504 +	 || (defined YYLTYPE_IS_TRIVIAL && YYLTYPE_IS_TRIVIAL \
   1.505 +	     && defined YYSTYPE_IS_TRIVIAL && YYSTYPE_IS_TRIVIAL)))
   1.506 +
   1.507 +/* A type that is properly aligned for any stack member.  */
   1.508 +union yyalloc
   1.509 +{
   1.510 +  yytype_int16 yyss_alloc;
   1.511 +  YYSTYPE yyvs_alloc;
   1.512 +  YYLTYPE yyls_alloc;
   1.513 +};
   1.514 +
   1.515 +/* The size of the maximum gap between one aligned stack and the next.  */
   1.516 +# define YYSTACK_GAP_MAXIMUM (sizeof (union yyalloc) - 1)
   1.517 +
   1.518 +/* The size of an array large to enough to hold all stacks, each with
   1.519 +   N elements.  */
   1.520 +# define YYSTACK_BYTES(N) \
   1.521 +     ((N) * (sizeof (yytype_int16) + sizeof (YYSTYPE) + sizeof (YYLTYPE)) \
   1.522 +      + 2 * YYSTACK_GAP_MAXIMUM)
   1.523 +
   1.524 +# define YYCOPY_NEEDED 1
   1.525 +
   1.526 +/* Relocate STACK from its old location to the new one.  The
   1.527 +   local variables YYSIZE and YYSTACKSIZE give the old and new number of
   1.528 +   elements in the stack, and YYPTR gives the new location of the
   1.529 +   stack.  Advance YYPTR to a properly aligned location for the next
   1.530 +   stack.  */
   1.531 +# define YYSTACK_RELOCATE(Stack_alloc, Stack)				\
   1.532 +    do									\
   1.533 +      {									\
   1.534 +	YYSIZE_T yynewbytes;						\
   1.535 +	YYCOPY (&yyptr->Stack_alloc, Stack, yysize);			\
   1.536 +	Stack = &yyptr->Stack_alloc;					\
   1.537 +	yynewbytes = yystacksize * sizeof (*Stack) + YYSTACK_GAP_MAXIMUM; \
   1.538 +	yyptr += yynewbytes / sizeof (*yyptr);				\
   1.539 +      }									\
   1.540 +    while (YYID (0))
   1.541 +
   1.542 +#endif
   1.543 +
   1.544 +#if defined YYCOPY_NEEDED && YYCOPY_NEEDED
   1.545 +/* Copy COUNT objects from SRC to DST.  The source and destination do
   1.546 +   not overlap.  */
   1.547 +# ifndef YYCOPY
   1.548 +#  if defined __GNUC__ && 1 < __GNUC__
   1.549 +#   define YYCOPY(Dst, Src, Count) \
   1.550 +      __builtin_memcpy (Dst, Src, (Count) * sizeof (*(Src)))
   1.551 +#  else
   1.552 +#   define YYCOPY(Dst, Src, Count)              \
   1.553 +      do                                        \
   1.554 +        {                                       \
   1.555 +          YYSIZE_T yyi;                         \
   1.556 +          for (yyi = 0; yyi < (Count); yyi++)   \
   1.557 +            (Dst)[yyi] = (Src)[yyi];            \
   1.558 +        }                                       \
   1.559 +      while (YYID (0))
   1.560 +#  endif
   1.561 +# endif
   1.562 +#endif /* !YYCOPY_NEEDED */
   1.563 +
   1.564 +/* YYFINAL -- State number of the termination state.  */
   1.565 +#define YYFINAL  74
   1.566 +/* YYLAST -- Last index in YYTABLE.  */
   1.567 +#define YYLAST   1490
   1.568 +
   1.569 +/* YYNTOKENS -- Number of terminals.  */
   1.570 +#define YYNTOKENS  95
   1.571 +/* YYNNTS -- Number of nonterminals.  */
   1.572 +#define YYNNTS  84
   1.573 +/* YYNRULES -- Number of rules.  */
   1.574 +#define YYNRULES  202
   1.575 +/* YYNRULES -- Number of states.  */
   1.576 +#define YYNSTATES  307
   1.577 +
   1.578 +/* YYTRANSLATE(YYLEX) -- Bison symbol number corresponding to YYLEX.  */
   1.579 +#define YYUNDEFTOK  2
   1.580 +#define YYMAXUTOK   349
   1.581 +
   1.582 +#define YYTRANSLATE(YYX)						\
   1.583 +  ((unsigned int) (YYX) <= YYMAXUTOK ? yytranslate[YYX] : YYUNDEFTOK)
   1.584 +
   1.585 +/* YYTRANSLATE[YYLEX] -- Bison symbol number corresponding to YYLEX.  */
   1.586 +static const yytype_uint8 yytranslate[] =
   1.587 +{
   1.588 +       0,     2,     2,     2,     2,     2,     2,     2,     2,     2,
   1.589 +       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
   1.590 +       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
   1.591 +       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
   1.592 +       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
   1.593 +       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
   1.594 +       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
   1.595 +       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
   1.596 +       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
   1.597 +       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
   1.598 +       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
   1.599 +       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
   1.600 +       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
   1.601 +       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
   1.602 +       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
   1.603 +       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
   1.604 +       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
   1.605 +       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
   1.606 +       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
   1.607 +       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
   1.608 +       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
   1.609 +       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
   1.610 +       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
   1.611 +       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
   1.612 +       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
   1.613 +       2,     2,     2,     2,     2,     2,     1,     2,     3,     4,
   1.614 +       5,     6,     7,     8,     9,    10,    11,    12,    13,    14,
   1.615 +      15,    16,    17,    18,    19,    20,    21,    22,    23,    24,
   1.616 +      25,    26,    27,    28,    29,    30,    31,    32,    33,    34,
   1.617 +      35,    36,    37,    38,    39,    40,    41,    42,    43,    44,
   1.618 +      45,    46,    47,    48,    49,    50,    51,    52,    53,    54,
   1.619 +      55,    56,    57,    58,    59,    60,    61,    62,    63,    64,
   1.620 +      65,    66,    67,    68,    69,    70,    71,    72,    73,    74,
   1.621 +      75,    76,    77,    78,    79,    80,    81,    82,    83,    84,
   1.622 +      85,    86,    87,    88,    89,    90,    91,    92,    93,    94
   1.623 +};
   1.624 +
   1.625 +#if YYDEBUG
   1.626 +/* YYPRHS[YYN] -- Index of the first RHS symbol of rule number YYN in
   1.627 +   YYRHS.  */
   1.628 +static const yytype_uint16 yyprhs[] =
   1.629 +{
   1.630 +       0,     0,     3,     5,     7,     9,    11,    13,    15,    17,
   1.631 +      21,    23,    28,    30,    34,    37,    40,    42,    44,    46,
   1.632 +      50,    53,    56,    59,    61,    64,    68,    71,    73,    75,
   1.633 +      77,    80,    83,    86,    88,    90,    92,    94,    98,   102,
   1.634 +     104,   108,   112,   114,   116,   120,   124,   128,   132,   134,
   1.635 +     138,   142,   144,   146,   148,   150,   154,   156,   160,   162,
   1.636 +     166,   168,   174,   176,   180,   182,   184,   186,   188,   190,
   1.637 +     192,   196,   198,   201,   204,   209,   212,   214,   216,   219,
   1.638 +     223,   227,   230,   236,   240,   243,   247,   250,   251,   253,
   1.639 +     255,   257,   259,   261,   265,   271,   278,   284,   286,   289,
   1.640 +     294,   300,   305,   308,   310,   313,   315,   317,   319,   322,
   1.641 +     324,   326,   329,   331,   333,   335,   337,   342,   344,   346,
   1.642 +     348,   350,   352,   354,   356,   358,   360,   362,   364,   366,
   1.643 +     368,   370,   372,   374,   376,   378,   380,   382,   384,   386,
   1.644 +     387,   394,   395,   401,   403,   406,   410,   412,   416,   418,
   1.645 +     423,   425,   427,   429,   431,   433,   435,   437,   439,   441,
   1.646 +     444,   445,   446,   452,   454,   456,   457,   460,   461,   464,
   1.647 +     467,   471,   473,   476,   478,   481,   487,   491,   493,   495,
   1.648 +     500,   501,   508,   509,   518,   519,   527,   529,   531,   533,
   1.649 +     534,   537,   541,   544,   547,   550,   554,   557,   559,   562,
   1.650 +     564,   566,   567
   1.651 +};
   1.652 +
   1.653 +/* YYRHS -- A `-1'-separated list of the rules' RHS.  */
   1.654 +static const yytype_int16 yyrhs[] =
   1.655 +{
   1.656 +     175,     0,    -1,    45,    -1,    46,    -1,    45,    -1,    97,
   1.657 +      -1,    48,    -1,    47,    -1,    49,    -1,    71,   124,    72,
   1.658 +      -1,    98,    -1,    99,    73,   100,    74,    -1,   101,    -1,
   1.659 +      99,    77,    96,    -1,    99,    52,    -1,    99,    53,    -1,
   1.660 +     124,    -1,   102,    -1,   103,    -1,    99,    77,   103,    -1,
   1.661 +     105,    72,    -1,   104,    72,    -1,   106,    39,    -1,   106,
   1.662 +      -1,   106,   122,    -1,   105,    78,   122,    -1,   107,    71,
   1.663 +      -1,   142,    -1,    45,    -1,    99,    -1,    52,   108,    -1,
   1.664 +      53,   108,    -1,   109,   108,    -1,    85,    -1,    83,    -1,
   1.665 +      82,    -1,   108,    -1,   110,    86,   108,    -1,   110,    87,
   1.666 +     108,    -1,   110,    -1,   111,    85,   110,    -1,   111,    83,
   1.667 +     110,    -1,   111,    -1,   112,    -1,   113,    89,   112,    -1,
   1.668 +     113,    90,   112,    -1,   113,    54,   112,    -1,   113,    55,
   1.669 +     112,    -1,   113,    -1,   114,    56,   113,    -1,   114,    57,
   1.670 +     113,    -1,   114,    -1,   115,    -1,   116,    -1,   117,    -1,
   1.671 +     118,    58,   117,    -1,   118,    -1,   119,    60,   118,    -1,
   1.672 +     119,    -1,   120,    59,   119,    -1,   120,    -1,   120,    94,
   1.673 +     124,    79,   122,    -1,   121,    -1,   108,   123,   122,    -1,
   1.674 +      80,    -1,    61,    -1,    62,    -1,    63,    -1,    70,    -1,
   1.675 +     122,    -1,   124,    78,   122,    -1,   121,    -1,   127,    81,
   1.676 +      -1,   135,    81,    -1,     7,   140,   141,    81,    -1,   128,
   1.677 +      72,    -1,   130,    -1,   129,    -1,   130,   132,    -1,   129,
   1.678 +      78,   132,    -1,   137,    45,    71,    -1,   139,    96,    -1,
   1.679 +     139,    96,    73,   125,    74,    -1,   138,   133,   131,    -1,
   1.680 +     133,   131,    -1,   138,   133,   134,    -1,   133,   134,    -1,
   1.681 +      -1,    33,    -1,    34,    -1,    35,    -1,   139,    -1,   136,
   1.682 +      -1,   135,    78,    96,    -1,   135,    78,    96,    73,    74,
   1.683 +      -1,   135,    78,    96,    73,   125,    74,    -1,   135,    78,
   1.684 +      96,    80,   150,    -1,   137,    -1,   137,    96,    -1,   137,
   1.685 +      96,    73,    74,    -1,   137,    96,    73,   125,    74,    -1,
   1.686 +     137,    96,    80,   150,    -1,     3,    45,    -1,   139,    -1,
   1.687 +     138,   139,    -1,     9,    -1,     8,    -1,    37,    -1,     3,
   1.688 +      37,    -1,    36,    -1,   141,    -1,   140,   141,    -1,     4,
   1.689 +      -1,     5,    -1,     6,    -1,   142,    -1,   142,    73,   125,
   1.690 +      74,    -1,    39,    -1,    11,    -1,    12,    -1,    10,    -1,
   1.691 +      27,    -1,    28,    -1,    29,    -1,    21,    -1,    22,    -1,
   1.692 +      23,    -1,    24,    -1,    25,    -1,    26,    -1,    30,    -1,
   1.693 +      31,    -1,    32,    -1,    41,    -1,    42,    -1,    43,    -1,
   1.694 +      44,    -1,   143,    -1,    46,    -1,    -1,    38,    96,    75,
   1.695 +     144,   146,    76,    -1,    -1,    38,    75,   145,   146,    76,
   1.696 +      -1,   147,    -1,   146,   147,    -1,   139,   148,    81,    -1,
   1.697 +     149,    -1,   148,    78,   149,    -1,    96,    -1,    96,    73,
   1.698 +     125,    74,    -1,   122,    -1,   126,    -1,   154,    -1,   153,
   1.699 +      -1,   151,    -1,   163,    -1,   164,    -1,   167,    -1,   174,
   1.700 +      -1,    75,    76,    -1,    -1,    -1,    75,   155,   162,   156,
   1.701 +      76,    -1,   161,    -1,   153,    -1,    -1,   159,   161,    -1,
   1.702 +      -1,   160,   153,    -1,    75,    76,    -1,    75,   162,    76,
   1.703 +      -1,   152,    -1,   162,   152,    -1,    81,    -1,   124,    81,
   1.704 +      -1,    18,    71,   124,    72,   165,    -1,   158,    16,   158,
   1.705 +      -1,   158,    -1,   124,    -1,   137,    96,    80,   150,    -1,
   1.706 +      -1,    40,    71,   168,   166,    72,   157,    -1,    -1,    15,
   1.707 +     169,   158,    40,    71,   124,    72,    81,    -1,    -1,    17,
   1.708 +      71,   170,   171,   173,    72,   157,    -1,   163,    -1,   151,
   1.709 +      -1,   166,    -1,    -1,   172,    81,    -1,   172,    81,   124,
   1.710 +      -1,    14,    81,    -1,    13,    81,    -1,    20,    81,    -1,
   1.711 +      20,   124,    81,    -1,    19,    81,    -1,   176,    -1,   175,
   1.712 +     176,    -1,   177,    -1,   126,    -1,    -1,   127,   178,   161,
   1.713 +      -1
   1.714 +};
   1.715 +
   1.716 +/* YYRLINE[YYN] -- source line where rule number YYN was defined.  */
   1.717 +static const yytype_uint16 yyrline[] =
   1.718 +{
   1.719 +       0,   179,   179,   180,   183,   226,   229,   242,   247,   252,
   1.720 +     258,   261,   264,   267,   362,   372,   385,   393,   493,   496,
   1.721 +     504,   507,   513,   517,   524,   530,   539,   547,   602,   612,
   1.722 +     615,   625,   635,   656,   657,   658,   663,   664,   672,   683,
   1.723 +     684,   692,   703,   707,   708,   718,   728,   738,   751,   752,
   1.724 +     762,   775,   779,   783,   787,   788,   801,   802,   815,   816,
   1.725 +     829,   830,   847,   848,   861,   862,   863,   864,   865,   869,
   1.726 +     872,   883,   891,   918,   923,   937,   992,   995,  1002,  1010,
   1.727 +    1031,  1052,  1062,  1090,  1095,  1105,  1110,  1120,  1123,  1126,
   1.728 +    1129,  1135,  1142,  1145,  1167,  1185,  1209,  1232,  1236,  1254,
   1.729 +    1262,  1294,  1314,  1335,  1344,  1367,  1370,  1376,  1384,  1392,
   1.730 +    1400,  1410,  1417,  1420,  1423,  1429,  1432,  1447,  1451,  1455,
   1.731 +    1459,  1463,  1468,  1473,  1478,  1483,  1488,  1493,  1498,  1503,
   1.732 +    1508,  1513,  1518,  1523,  1527,  1531,  1539,  1547,  1551,  1564,
   1.733 +    1564,  1578,  1578,  1587,  1590,  1606,  1639,  1643,  1649,  1656,
   1.734 +    1671,  1675,  1679,  1680,  1686,  1687,  1688,  1689,  1690,  1694,
   1.735 +    1695,  1695,  1695,  1705,  1706,  1710,  1710,  1711,  1711,  1716,
   1.736 +    1719,  1729,  1732,  1738,  1739,  1743,  1751,  1755,  1765,  1770,
   1.737 +    1787,  1787,  1792,  1792,  1799,  1799,  1807,  1810,  1816,  1819,
   1.738 +    1825,  1829,  1836,  1843,  1850,  1857,  1868,  1877,  1881,  1888,
   1.739 +    1891,  1897,  1897
   1.740 +};
   1.741 +#endif
   1.742 +
   1.743 +#if YYDEBUG || YYERROR_VERBOSE || 0
   1.744 +/* YYTNAME[SYMBOL-NUM] -- String name of the symbol SYMBOL-NUM.
   1.745 +   First, the terminals, then, starting at YYNTOKENS, nonterminals.  */
   1.746 +static const char *const yytname[] =
   1.747 +{
   1.748 +  "$end", "error", "$undefined", "INVARIANT", "HIGH_PRECISION",
   1.749 +  "MEDIUM_PRECISION", "LOW_PRECISION", "PRECISION", "ATTRIBUTE",
   1.750 +  "CONST_QUAL", "BOOL_TYPE", "FLOAT_TYPE", "INT_TYPE", "BREAK", "CONTINUE",
   1.751 +  "DO", "ELSE", "FOR", "IF", "DISCARD", "RETURN", "BVEC2", "BVEC3",
   1.752 +  "BVEC4", "IVEC2", "IVEC3", "IVEC4", "VEC2", "VEC3", "VEC4", "MATRIX2",
   1.753 +  "MATRIX3", "MATRIX4", "IN_QUAL", "OUT_QUAL", "INOUT_QUAL", "UNIFORM",
   1.754 +  "VARYING", "STRUCT", "VOID_TYPE", "WHILE", "SAMPLER2D", "SAMPLERCUBE",
   1.755 +  "SAMPLER_EXTERNAL_OES", "SAMPLER2DRECT", "IDENTIFIER", "TYPE_NAME",
   1.756 +  "FLOATCONSTANT", "INTCONSTANT", "BOOLCONSTANT", "LEFT_OP", "RIGHT_OP",
   1.757 +  "INC_OP", "DEC_OP", "LE_OP", "GE_OP", "EQ_OP", "NE_OP", "AND_OP",
   1.758 +  "OR_OP", "XOR_OP", "MUL_ASSIGN", "DIV_ASSIGN", "ADD_ASSIGN",
   1.759 +  "MOD_ASSIGN", "LEFT_ASSIGN", "RIGHT_ASSIGN", "AND_ASSIGN", "XOR_ASSIGN",
   1.760 +  "OR_ASSIGN", "SUB_ASSIGN", "LEFT_PAREN", "RIGHT_PAREN", "LEFT_BRACKET",
   1.761 +  "RIGHT_BRACKET", "LEFT_BRACE", "RIGHT_BRACE", "DOT", "COMMA", "COLON",
   1.762 +  "EQUAL", "SEMICOLON", "BANG", "DASH", "TILDE", "PLUS", "STAR", "SLASH",
   1.763 +  "PERCENT", "LEFT_ANGLE", "RIGHT_ANGLE", "VERTICAL_BAR", "CARET",
   1.764 +  "AMPERSAND", "QUESTION", "$accept", "identifier", "variable_identifier",
   1.765 +  "primary_expression", "postfix_expression", "integer_expression",
   1.766 +  "function_call", "function_call_or_method", "function_call_generic",
   1.767 +  "function_call_header_no_parameters",
   1.768 +  "function_call_header_with_parameters", "function_call_header",
   1.769 +  "function_identifier", "unary_expression", "unary_operator",
   1.770 +  "multiplicative_expression", "additive_expression", "shift_expression",
   1.771 +  "relational_expression", "equality_expression", "and_expression",
   1.772 +  "exclusive_or_expression", "inclusive_or_expression",
   1.773 +  "logical_and_expression", "logical_xor_expression",
   1.774 +  "logical_or_expression", "conditional_expression",
   1.775 +  "assignment_expression", "assignment_operator", "expression",
   1.776 +  "constant_expression", "declaration", "function_prototype",
   1.777 +  "function_declarator", "function_header_with_parameters",
   1.778 +  "function_header", "parameter_declarator", "parameter_declaration",
   1.779 +  "parameter_qualifier", "parameter_type_specifier",
   1.780 +  "init_declarator_list", "single_declaration", "fully_specified_type",
   1.781 +  "type_qualifier", "type_specifier", "precision_qualifier",
   1.782 +  "type_specifier_no_prec", "type_specifier_nonarray", "struct_specifier",
   1.783 +  "$@1", "$@2", "struct_declaration_list", "struct_declaration",
   1.784 +  "struct_declarator_list", "struct_declarator", "initializer",
   1.785 +  "declaration_statement", "statement", "simple_statement",
   1.786 +  "compound_statement", "$@3", "$@4", "statement_no_new_scope",
   1.787 +  "statement_with_scope", "$@5", "$@6", "compound_statement_no_new_scope",
   1.788 +  "statement_list", "expression_statement", "selection_statement",
   1.789 +  "selection_rest_statement", "condition", "iteration_statement", "$@7",
   1.790 +  "$@8", "$@9", "for_init_statement", "conditionopt", "for_rest_statement",
   1.791 +  "jump_statement", "translation_unit", "external_declaration",
   1.792 +  "function_definition", "$@10", YY_NULL
   1.793 +};
   1.794 +#endif
   1.795 +
   1.796 +# ifdef YYPRINT
   1.797 +/* YYTOKNUM[YYLEX-NUM] -- Internal token number corresponding to
   1.798 +   token YYLEX-NUM.  */
   1.799 +static const yytype_uint16 yytoknum[] =
   1.800 +{
   1.801 +       0,   256,   257,   258,   259,   260,   261,   262,   263,   264,
   1.802 +     265,   266,   267,   268,   269,   270,   271,   272,   273,   274,
   1.803 +     275,   276,   277,   278,   279,   280,   281,   282,   283,   284,
   1.804 +     285,   286,   287,   288,   289,   290,   291,   292,   293,   294,
   1.805 +     295,   296,   297,   298,   299,   300,   301,   302,   303,   304,
   1.806 +     305,   306,   307,   308,   309,   310,   311,   312,   313,   314,
   1.807 +     315,   316,   317,   318,   319,   320,   321,   322,   323,   324,
   1.808 +     325,   326,   327,   328,   329,   330,   331,   332,   333,   334,
   1.809 +     335,   336,   337,   338,   339,   340,   341,   342,   343,   344,
   1.810 +     345,   346,   347,   348,   349
   1.811 +};
   1.812 +# endif
   1.813 +
   1.814 +/* YYR1[YYN] -- Symbol number of symbol that rule YYN derives.  */
   1.815 +static const yytype_uint8 yyr1[] =
   1.816 +{
   1.817 +       0,    95,    96,    96,    97,    98,    98,    98,    98,    98,
   1.818 +      99,    99,    99,    99,    99,    99,   100,   101,   102,   102,
   1.819 +     103,   103,   104,   104,   105,   105,   106,   107,   107,   108,
   1.820 +     108,   108,   108,   109,   109,   109,   110,   110,   110,   111,
   1.821 +     111,   111,   112,   113,   113,   113,   113,   113,   114,   114,
   1.822 +     114,   115,   116,   117,   118,   118,   119,   119,   120,   120,
   1.823 +     121,   121,   122,   122,   123,   123,   123,   123,   123,   124,
   1.824 +     124,   125,   126,   126,   126,   127,   128,   128,   129,   129,
   1.825 +     130,   131,   131,   132,   132,   132,   132,   133,   133,   133,
   1.826 +     133,   134,   135,   135,   135,   135,   135,   136,   136,   136,
   1.827 +     136,   136,   136,   137,   137,   138,   138,   138,   138,   138,
   1.828 +     139,   139,   140,   140,   140,   141,   141,   142,   142,   142,
   1.829 +     142,   142,   142,   142,   142,   142,   142,   142,   142,   142,
   1.830 +     142,   142,   142,   142,   142,   142,   142,   142,   142,   144,
   1.831 +     143,   145,   143,   146,   146,   147,   148,   148,   149,   149,
   1.832 +     150,   151,   152,   152,   153,   153,   153,   153,   153,   154,
   1.833 +     155,   156,   154,   157,   157,   159,   158,   160,   158,   161,
   1.834 +     161,   162,   162,   163,   163,   164,   165,   165,   166,   166,
   1.835 +     168,   167,   169,   167,   170,   167,   171,   171,   172,   172,
   1.836 +     173,   173,   174,   174,   174,   174,   174,   175,   175,   176,
   1.837 +     176,   178,   177
   1.838 +};
   1.839 +
   1.840 +/* YYR2[YYN] -- Number of symbols composing right hand side of rule YYN.  */
   1.841 +static const yytype_uint8 yyr2[] =
   1.842 +{
   1.843 +       0,     2,     1,     1,     1,     1,     1,     1,     1,     3,
   1.844 +       1,     4,     1,     3,     2,     2,     1,     1,     1,     3,
   1.845 +       2,     2,     2,     1,     2,     3,     2,     1,     1,     1,
   1.846 +       2,     2,     2,     1,     1,     1,     1,     3,     3,     1,
   1.847 +       3,     3,     1,     1,     3,     3,     3,     3,     1,     3,
   1.848 +       3,     1,     1,     1,     1,     3,     1,     3,     1,     3,
   1.849 +       1,     5,     1,     3,     1,     1,     1,     1,     1,     1,
   1.850 +       3,     1,     2,     2,     4,     2,     1,     1,     2,     3,
   1.851 +       3,     2,     5,     3,     2,     3,     2,     0,     1,     1,
   1.852 +       1,     1,     1,     3,     5,     6,     5,     1,     2,     4,
   1.853 +       5,     4,     2,     1,     2,     1,     1,     1,     2,     1,
   1.854 +       1,     2,     1,     1,     1,     1,     4,     1,     1,     1,
   1.855 +       1,     1,     1,     1,     1,     1,     1,     1,     1,     1,
   1.856 +       1,     1,     1,     1,     1,     1,     1,     1,     1,     0,
   1.857 +       6,     0,     5,     1,     2,     3,     1,     3,     1,     4,
   1.858 +       1,     1,     1,     1,     1,     1,     1,     1,     1,     2,
   1.859 +       0,     0,     5,     1,     1,     0,     2,     0,     2,     2,
   1.860 +       3,     1,     2,     1,     2,     5,     3,     1,     1,     4,
   1.861 +       0,     6,     0,     8,     0,     7,     1,     1,     1,     0,
   1.862 +       2,     3,     2,     2,     2,     3,     2,     1,     2,     1,
   1.863 +       1,     0,     3
   1.864 +};
   1.865 +
   1.866 +/* YYDEFACT[STATE-NAME] -- Default reduction number in state STATE-NUM.
   1.867 +   Performed when YYTABLE doesn't specify something else to do.  Zero
   1.868 +   means the default is an error.  */
   1.869 +static const yytype_uint8 yydefact[] =
   1.870 +{
   1.871 +       0,     0,   112,   113,   114,     0,   106,   105,   120,   118,
   1.872 +     119,   124,   125,   126,   127,   128,   129,   121,   122,   123,
   1.873 +     130,   131,   132,   109,   107,     0,   117,   133,   134,   135,
   1.874 +     136,   138,   200,   201,     0,    77,    87,     0,    92,    97,
   1.875 +       0,   103,     0,   110,   115,   137,     0,   197,   199,   108,
   1.876 +     102,     0,     2,     3,   141,     0,    72,     0,    75,    87,
   1.877 +       0,    88,    89,    90,    78,     0,    87,     0,    73,     2,
   1.878 +      98,   104,   111,     0,     1,   198,     0,     0,   139,     0,
   1.879 +     202,    79,    84,    86,    91,     0,    93,    80,     0,     0,
   1.880 +       4,     7,     6,     8,     0,     0,     0,    35,    34,    33,
   1.881 +       5,    10,    29,    12,    17,    18,     0,     0,    23,     0,
   1.882 +      36,     0,    39,    42,    43,    48,    51,    52,    53,    54,
   1.883 +      56,    58,    60,    71,     0,    27,    74,     0,     0,   143,
   1.884 +       0,     0,     0,   182,     0,     0,     0,     0,     0,   160,
   1.885 +     169,   173,    36,    62,    69,     0,   151,     0,   115,   154,
   1.886 +     171,   153,   152,     0,   155,   156,   157,   158,    81,    83,
   1.887 +      85,     0,     0,    99,     0,   150,   101,    30,    31,     0,
   1.888 +      14,    15,     0,     0,    21,    20,     0,    22,    24,    26,
   1.889 +      32,     0,     0,     0,     0,     0,     0,     0,     0,     0,
   1.890 +       0,     0,     0,     0,     0,   116,   148,     0,   146,   142,
   1.891 +     144,     0,   193,   192,   167,   184,     0,   196,   194,     0,
   1.892 +     180,   159,     0,    65,    66,    67,    68,    64,     0,     0,
   1.893 +     174,   170,   172,     0,    94,     0,    96,   100,     9,     0,
   1.894 +      16,     2,     3,    13,    19,    25,    37,    38,    41,    40,
   1.895 +      46,    47,    44,    45,    49,    50,    55,    57,    59,     0,
   1.896 +       0,     0,   145,   140,     0,     0,     0,     0,     0,   195,
   1.897 +       0,   161,    63,    70,     0,    95,    11,     0,     0,   147,
   1.898 +       0,   166,   168,   187,   186,   189,   167,   178,     0,     0,
   1.899 +       0,    82,    61,   149,     0,   188,     0,     0,   177,   175,
   1.900 +       0,     0,   162,     0,   190,     0,   167,     0,   164,   181,
   1.901 +     163,     0,   191,   185,   176,   179,   183
   1.902 +};
   1.903 +
   1.904 +/* YYDEFGOTO[NTERM-NUM].  */
   1.905 +static const yytype_int16 yydefgoto[] =
   1.906 +{
   1.907 +      -1,   196,   100,   101,   102,   229,   103,   104,   105,   106,
   1.908 +     107,   108,   109,   142,   111,   112,   113,   114,   115,   116,
   1.909 +     117,   118,   119,   120,   121,   122,   143,   144,   218,   145,
   1.910 +     124,   146,   147,    34,    35,    36,    82,    64,    65,    83,
   1.911 +      37,    38,    39,    40,    41,    42,    43,   125,    45,   130,
   1.912 +      77,   128,   129,   197,   198,   166,   149,   150,   151,   152,
   1.913 +     212,   280,   299,   254,   255,   256,   300,   153,   154,   155,
   1.914 +     289,   279,   156,   260,   204,   257,   275,   286,   287,   157,
   1.915 +      46,    47,    48,    57
   1.916 +};
   1.917 +
   1.918 +/* YYPACT[STATE-NUM] -- Index in YYTABLE of the portion describing
   1.919 +   STATE-NUM.  */
   1.920 +#define YYPACT_NINF -261
   1.921 +static const yytype_int16 yypact[] =
   1.922 +{
   1.923 +    1327,   -20,  -261,  -261,  -261,   113,  -261,  -261,  -261,  -261,
   1.924 +    -261,  -261,  -261,  -261,  -261,  -261,  -261,  -261,  -261,  -261,
   1.925 +    -261,  -261,  -261,  -261,  -261,   -19,  -261,  -261,  -261,  -261,
   1.926 +    -261,  -261,  -261,   -61,   -40,   -28,    75,    -7,  -261,    24,
   1.927 +    1370,  -261,  1444,  -261,   -11,  -261,  1283,  -261,  -261,  -261,
   1.928 +    -261,  1444,  -261,  -261,  -261,     6,  -261,    54,  -261,    88,
   1.929 +      62,  -261,  -261,  -261,  -261,  1370,    59,    91,  -261,    36,
   1.930 +     -50,  -261,  -261,  1051,  -261,  -261,    63,  1370,  -261,   293,
   1.931 +    -261,  -261,  -261,  -261,    91,  1370,   -12,  -261,   856,  1051,
   1.932 +      77,  -261,  -261,  -261,  1051,  1051,  1051,  -261,  -261,  -261,
   1.933 +    -261,  -261,   -14,  -261,  -261,  -261,    84,   -44,  1116,    95,
   1.934 +    -261,  1051,    53,     3,  -261,   -36,    89,  -261,  -261,  -261,
   1.935 +     104,   107,   -45,  -261,    96,  -261,  -261,    91,  1184,  -261,
   1.936 +    1370,    92,    93,  -261,    98,   101,    94,   921,   105,   102,
   1.937 +    -261,  -261,    72,  -261,  -261,     9,  -261,   -61,    42,  -261,
   1.938 +    -261,  -261,  -261,   376,  -261,  -261,  -261,  -261,   106,  -261,
   1.939 +    -261,   986,  1051,  -261,   103,  -261,  -261,  -261,  -261,   -41,
   1.940 +    -261,  -261,  1051,  1407,  -261,  -261,  1051,   110,  -261,  -261,
   1.941 +    -261,  1051,  1051,  1051,  1051,  1051,  1051,  1051,  1051,  1051,
   1.942 +    1051,  1051,  1051,  1051,  1051,  -261,   109,    23,  -261,  -261,
   1.943 +    -261,  1227,  -261,  -261,   111,  -261,  1051,  -261,  -261,    25,
   1.944 +    -261,  -261,   459,  -261,  -261,  -261,  -261,  -261,  1051,  1051,
   1.945 +    -261,  -261,  -261,  1051,  -261,   114,  -261,  -261,  -261,   115,
   1.946 +     112,    77,   116,  -261,  -261,  -261,  -261,  -261,    53,    53,
   1.947 +    -261,  -261,  -261,  -261,   -36,   -36,  -261,   104,   107,    76,
   1.948 +    1051,    91,  -261,  -261,   145,    54,   625,   708,    -6,  -261,
   1.949 +     791,   459,  -261,  -261,   117,  -261,  -261,  1051,   120,  -261,
   1.950 +     124,  -261,  -261,  -261,  -261,   791,   111,   112,    91,   125,
   1.951 +     122,  -261,  -261,  -261,  1051,  -261,   118,   128,   180,  -261,
   1.952 +     126,   542,  -261,    -5,  1051,   542,   111,  1051,  -261,  -261,
   1.953 +    -261,   123,   112,  -261,  -261,  -261,  -261
   1.954 +};
   1.955 +
   1.956 +/* YYPGOTO[NTERM-NUM].  */
   1.957 +static const yytype_int16 yypgoto[] =
   1.958 +{
   1.959 +    -261,   -24,  -261,  -261,  -261,  -261,  -261,  -261,    34,  -261,
   1.960 +    -261,  -261,  -261,    32,  -261,   -33,  -261,   -27,   -26,  -261,
   1.961 +    -261,  -261,    14,    16,    18,  -261,   -66,   -87,  -261,   -92,
   1.962 +     -85,    11,    12,  -261,  -261,  -261,   141,   150,   161,   143,
   1.963 +    -261,  -261,  -231,     5,   -30,   224,   -18,     0,  -261,  -261,
   1.964 +    -261,   100,  -119,  -261,   -17,  -156,   -25,  -145,  -243,  -261,
   1.965 +    -261,  -261,   -64,  -260,  -261,  -261,   -52,    21,   -22,  -261,
   1.966 +    -261,   -39,  -261,  -261,  -261,  -261,  -261,  -261,  -261,  -261,
   1.967 +    -261,   191,  -261,  -261
   1.968 +};
   1.969 +
   1.970 +/* YYTABLE[YYPACT[STATE-NUM]].  What to do in state STATE-NUM.  If
   1.971 +   positive, shift that token.  If negative, reduce the rule which
   1.972 +   number is the opposite.  If YYTABLE_NINF, syntax error.  */
   1.973 +#define YYTABLE_NINF -166
   1.974 +static const yytype_int16 yytable[] =
   1.975 +{
   1.976 +      44,    55,   165,   164,   169,    80,   226,   123,   222,   200,
   1.977 +      71,    32,    33,   272,   193,    70,   288,    49,   185,   186,
   1.978 +      56,   178,   123,    88,    72,    50,    52,    53,   175,   278,
   1.979 +      89,   228,    58,    76,   176,    84,   304,   219,   170,   171,
   1.980 +      44,    66,    44,    86,   278,   209,    44,   127,   298,   194,
   1.981 +      59,    44,   298,   187,   188,    84,    54,    32,    33,   172,
   1.982 +     158,   161,    73,   173,    66,    44,   276,   301,   162,    69,
   1.983 +      53,    67,   219,   219,    68,   165,   225,    44,    60,   148,
   1.984 +     230,    78,   200,     6,     7,    44,   183,   219,   184,   235,
   1.985 +     220,    60,    61,    62,    63,   123,     6,     7,   127,    49,
   1.986 +     127,   251,   249,   219,   252,   110,   259,    87,    61,    62,
   1.987 +      63,    23,    24,   -27,   258,    73,   222,     2,     3,     4,
   1.988 +     110,    61,    62,    63,    23,    24,   167,   168,    44,    79,
   1.989 +      44,   262,   263,   213,   214,   215,    52,    53,   264,   181,
   1.990 +     182,   305,   216,   180,   126,   189,   190,   -76,   -28,   233,
   1.991 +     238,   239,   217,   148,   219,   267,   174,   123,   240,   241,
   1.992 +     242,   243,   191,   244,   245,   268,   179,   192,   277,   205,
   1.993 +     195,   127,   206,   202,   203,   207,   210,   227,   211,   223,
   1.994 +     282,  -117,   250,   277,   123,   270,  -165,  -138,   265,   266,
   1.995 +     219,   281,   293,   110,   283,   284,   296,   291,   292,   294,
   1.996 +     295,    44,   302,   271,   306,   246,   297,   234,   247,    81,
   1.997 +     165,   248,   148,   236,   237,   110,   110,   110,   110,   110,
   1.998 +     110,   110,   110,   110,   110,   110,   159,    85,   160,    51,
   1.999 +     201,   303,   273,   261,   269,   274,   285,    75,     0,     0,
  1.1000 +       0,     0,     0,     0,     0,     0,     0,     0,     0,     0,
  1.1001 +       0,     0,     0,     0,   290,   110,   148,   148,     0,     0,
  1.1002 +     148,   148,     0,     0,     0,     0,     0,     0,     0,     0,
  1.1003 +       0,     0,     0,     0,     0,   148,     0,     0,     0,     0,
  1.1004 +       0,     0,   110,     0,     0,     0,     0,     0,     0,     0,
  1.1005 +       0,   148,     0,     0,     0,   148,     1,     2,     3,     4,
  1.1006 +       5,     6,     7,     8,     9,    10,   131,   132,   133,     0,
  1.1007 +     134,   135,   136,   137,    11,    12,    13,    14,    15,    16,
  1.1008 +      17,    18,    19,    20,    21,    22,     0,     0,     0,    23,
  1.1009 +      24,    25,    26,   138,    27,    28,    29,    30,    90,    31,
  1.1010 +      91,    92,    93,     0,     0,    94,    95,     0,     0,     0,
  1.1011 +       0,     0,     0,     0,     0,     0,     0,     0,     0,     0,
  1.1012 +       0,     0,     0,     0,    96,     0,     0,     0,   139,   140,
  1.1013 +       0,     0,     0,     0,   141,    97,    98,     0,    99,     1,
  1.1014 +       2,     3,     4,     5,     6,     7,     8,     9,    10,   131,
  1.1015 +     132,   133,     0,   134,   135,   136,   137,    11,    12,    13,
  1.1016 +      14,    15,    16,    17,    18,    19,    20,    21,    22,     0,
  1.1017 +       0,     0,    23,    24,    25,    26,   138,    27,    28,    29,
  1.1018 +      30,    90,    31,    91,    92,    93,     0,     0,    94,    95,
  1.1019 +       0,     0,     0,     0,     0,     0,     0,     0,     0,     0,
  1.1020 +       0,     0,     0,     0,     0,     0,     0,    96,     0,     0,
  1.1021 +       0,   139,   221,     0,     0,     0,     0,   141,    97,    98,
  1.1022 +       0,    99,     1,     2,     3,     4,     5,     6,     7,     8,
  1.1023 +       9,    10,   131,   132,   133,     0,   134,   135,   136,   137,
  1.1024 +      11,    12,    13,    14,    15,    16,    17,    18,    19,    20,
  1.1025 +      21,    22,     0,     0,     0,    23,    24,    25,    26,   138,
  1.1026 +      27,    28,    29,    30,    90,    31,    91,    92,    93,     0,
  1.1027 +       0,    94,    95,     0,     0,     0,     0,     0,     0,     0,
  1.1028 +       0,     0,     0,     0,     0,     0,     0,     0,     0,     0,
  1.1029 +      96,     0,     0,     0,   139,     0,     0,     0,     0,     0,
  1.1030 +     141,    97,    98,     0,    99,     1,     2,     3,     4,     5,
  1.1031 +       6,     7,     8,     9,    10,   131,   132,   133,     0,   134,
  1.1032 +     135,   136,   137,    11,    12,    13,    14,    15,    16,    17,
  1.1033 +      18,    19,    20,    21,    22,     0,     0,     0,    23,    24,
  1.1034 +      25,    26,   138,    27,    28,    29,    30,    90,    31,    91,
  1.1035 +      92,    93,     0,     0,    94,    95,     0,     0,     0,     0,
  1.1036 +       0,     0,     0,     0,     0,     0,     0,     0,     0,     0,
  1.1037 +       0,     0,     0,    96,     0,     0,     0,    79,     0,     0,
  1.1038 +       0,     0,     0,   141,    97,    98,     0,    99,     1,     2,
  1.1039 +       3,     4,     5,     6,     7,     8,     9,    10,   131,   132,
  1.1040 +     133,     0,   134,   135,   136,   137,    11,    12,    13,    14,
  1.1041 +      15,    16,    17,    18,    19,    20,    21,    22,     0,     0,
  1.1042 +       0,    23,    24,    25,    26,   138,    27,    28,    29,    30,
  1.1043 +      90,    31,    91,    92,    93,     0,     0,    94,    95,     0,
  1.1044 +       0,     0,     0,     0,     0,     0,     0,     0,     0,     0,
  1.1045 +       0,     0,     0,     0,     0,     0,    96,     0,     0,     0,
  1.1046 +       0,     0,     0,     0,     0,     0,   141,    97,    98,     0,
  1.1047 +      99,     1,     2,     3,     4,     5,     6,     7,     8,     9,
  1.1048 +      10,     0,     0,     0,     0,     0,     0,     0,     0,    11,
  1.1049 +      12,    13,    14,    15,    16,    17,    18,    19,    20,    21,
  1.1050 +      22,     0,     0,     0,    23,    24,    25,    26,     0,    27,
  1.1051 +      28,    29,    30,    90,    31,    91,    92,    93,     0,     0,
  1.1052 +      94,    95,     0,     0,     0,     0,     0,     0,     0,     0,
  1.1053 +       0,     0,     0,     0,     0,     0,     0,     0,     0,    96,
  1.1054 +       0,     0,     0,     0,     0,     0,     0,     0,     0,   141,
  1.1055 +      97,    98,     0,    99,    60,     2,     3,     4,     0,     6,
  1.1056 +       7,     8,     9,    10,     0,     0,     0,     0,     0,     0,
  1.1057 +       0,     0,    11,    12,    13,    14,    15,    16,    17,    18,
  1.1058 +      19,    20,    21,    22,     0,     0,     0,    23,    24,    25,
  1.1059 +      26,     0,    27,    28,    29,    30,    90,    31,    91,    92,
  1.1060 +      93,     0,     0,    94,    95,     0,     0,     0,     0,     0,
  1.1061 +       0,     0,     0,     0,     0,     0,     0,     0,     0,     0,
  1.1062 +       0,     0,    96,     0,     0,     0,     8,     9,    10,     0,
  1.1063 +       0,     0,     0,    97,    98,     0,    99,    11,    12,    13,
  1.1064 +      14,    15,    16,    17,    18,    19,    20,    21,    22,     0,
  1.1065 +       0,     0,     0,     0,    25,    26,     0,    27,    28,    29,
  1.1066 +      30,    90,    31,    91,    92,    93,     0,     0,    94,    95,
  1.1067 +       0,     0,     0,     0,     0,     0,     0,     0,     0,     0,
  1.1068 +       0,     0,     0,     0,     0,     0,     0,    96,     0,     0,
  1.1069 +     163,     8,     9,    10,     0,     0,     0,     0,    97,    98,
  1.1070 +       0,    99,    11,    12,    13,    14,    15,    16,    17,    18,
  1.1071 +      19,    20,    21,    22,     0,     0,     0,     0,     0,    25,
  1.1072 +      26,     0,    27,    28,    29,    30,    90,    31,    91,    92,
  1.1073 +      93,     0,     0,    94,    95,     0,     0,     0,     0,     0,
  1.1074 +       0,     0,     0,     0,     0,     0,     0,     0,     0,     0,
  1.1075 +       0,     0,    96,     0,     0,     0,     8,     9,    10,     0,
  1.1076 +       0,     0,   208,    97,    98,     0,    99,    11,    12,    13,
  1.1077 +      14,    15,    16,    17,    18,    19,    20,    21,    22,     0,
  1.1078 +       0,     0,     0,     0,    25,    26,     0,    27,    28,    29,
  1.1079 +      30,    90,    31,    91,    92,    93,     0,     0,    94,    95,
  1.1080 +       0,     0,     0,     0,     0,     0,     0,     0,     0,     0,
  1.1081 +       0,     0,     0,     0,     0,     0,     0,    96,     0,     0,
  1.1082 +     224,     8,     9,    10,     0,     0,     0,     0,    97,    98,
  1.1083 +       0,    99,    11,    12,    13,    14,    15,    16,    17,    18,
  1.1084 +      19,    20,    21,    22,     0,     0,     0,     0,     0,    25,
  1.1085 +      26,     0,    27,    28,    29,    30,    90,    31,    91,    92,
  1.1086 +      93,     0,     0,    94,    95,     0,     0,     0,     0,     0,
  1.1087 +       0,     0,     0,     0,     0,     0,     0,     0,     0,     0,
  1.1088 +       0,     0,    96,     0,     0,     0,     8,     9,    10,     0,
  1.1089 +       0,     0,     0,    97,    98,     0,    99,    11,    12,    13,
  1.1090 +      14,    15,    16,    17,    18,    19,    20,    21,    22,     0,
  1.1091 +       0,     0,     0,     0,    25,   177,     0,    27,    28,    29,
  1.1092 +      30,    90,    31,    91,    92,    93,     0,     0,    94,    95,
  1.1093 +       0,     0,     0,     0,     0,     0,     0,     0,     0,     0,
  1.1094 +       0,     0,     0,     0,     0,     0,     0,    96,     2,     3,
  1.1095 +       4,     0,     0,     0,     8,     9,    10,     0,    97,    98,
  1.1096 +       0,    99,     0,     0,     0,    11,    12,    13,    14,    15,
  1.1097 +      16,    17,    18,    19,    20,    21,    22,     0,     0,     0,
  1.1098 +       0,     0,    25,    26,     0,    27,    28,    29,    30,     0,
  1.1099 +      31,     2,     3,     4,     0,     0,     0,     8,     9,    10,
  1.1100 +       0,     0,     0,     0,     0,     0,     0,     0,    11,    12,
  1.1101 +      13,    14,    15,    16,    17,    18,    19,    20,    21,    22,
  1.1102 +     199,     0,     0,     0,     0,    25,    26,     0,    27,    28,
  1.1103 +      29,    30,     0,    31,     0,     0,     0,     0,     0,     0,
  1.1104 +       0,     0,     0,    74,     0,     0,     1,     2,     3,     4,
  1.1105 +       5,     6,     7,     8,     9,    10,     0,     0,     0,     0,
  1.1106 +       0,     0,     0,   253,    11,    12,    13,    14,    15,    16,
  1.1107 +      17,    18,    19,    20,    21,    22,     0,     0,     0,    23,
  1.1108 +      24,    25,    26,     0,    27,    28,    29,    30,     0,    31,
  1.1109 +       1,     2,     3,     4,     5,     6,     7,     8,     9,    10,
  1.1110 +       0,     0,     0,     0,     0,     0,     0,     0,    11,    12,
  1.1111 +      13,    14,    15,    16,    17,    18,    19,    20,    21,    22,
  1.1112 +       0,     0,     0,    23,    24,    25,    26,     0,    27,    28,
  1.1113 +      29,    30,     0,    31,     2,     3,     4,     0,     0,     0,
  1.1114 +       8,     9,    10,     0,     0,     0,     0,     0,     0,     0,
  1.1115 +       0,    11,    12,    13,    14,    15,    16,    17,    18,    19,
  1.1116 +      20,    21,    22,     0,     0,     0,     0,     0,    25,    26,
  1.1117 +       0,    27,    28,    29,    30,     0,    31,     8,     9,    10,
  1.1118 +       0,     0,     0,     0,     0,     0,     0,     0,    11,    12,
  1.1119 +      13,    14,    15,    16,    17,    18,    19,    20,    21,    22,
  1.1120 +       0,     0,     0,     0,     0,    25,    26,     0,    27,    28,
  1.1121 +      29,    30,   231,   232,     8,     9,    10,     0,     0,     0,
  1.1122 +       0,     0,     0,     0,     0,    11,    12,    13,    14,    15,
  1.1123 +      16,    17,    18,    19,    20,    21,    22,     0,     0,     0,
  1.1124 +       0,     0,    25,    26,     0,    27,    28,    29,    30,     0,
  1.1125 +      31
  1.1126 +};
  1.1127 +
  1.1128 +#define yypact_value_is_default(Yystate) \
  1.1129 +  (!!((Yystate) == (-261)))
  1.1130 +
  1.1131 +#define yytable_value_is_error(Yytable_value) \
  1.1132 +  YYID (0)
  1.1133 +
  1.1134 +static const yytype_int16 yycheck[] =
  1.1135 +{
  1.1136 +       0,    25,    89,    88,    96,    57,   162,    73,   153,   128,
  1.1137 +      40,     0,     0,   256,    59,    39,   276,    37,    54,    55,
  1.1138 +      81,   108,    88,    73,    42,    45,    45,    46,    72,   260,
  1.1139 +      80,    72,    72,    51,    78,    65,   296,    78,    52,    53,
  1.1140 +      40,    36,    42,    67,   275,   137,    46,    77,   291,    94,
  1.1141 +      78,    51,   295,    89,    90,    85,    75,    46,    46,    73,
  1.1142 +      84,    73,    73,    77,    59,    65,    72,    72,    80,    45,
  1.1143 +      46,    78,    78,    78,    81,   162,   161,    77,     3,    79,
  1.1144 +     172,    75,   201,     8,     9,    85,    83,    78,    85,   176,
  1.1145 +      81,     3,    33,    34,    35,   161,     8,     9,   128,    37,
  1.1146 +     130,    78,   194,    78,    81,    73,    81,    71,    33,    34,
  1.1147 +      35,    36,    37,    71,   206,    73,   261,     4,     5,     6,
  1.1148 +      88,    33,    34,    35,    36,    37,    94,    95,   128,    75,
  1.1149 +     130,   218,   219,    61,    62,    63,    45,    46,   223,    86,
  1.1150 +      87,   297,    70,   111,    81,    56,    57,    72,    71,   173,
  1.1151 +     183,   184,    80,   153,    78,    79,    72,   223,   185,   186,
  1.1152 +     187,   188,    58,   189,   190,   250,    71,    60,   260,    71,
  1.1153 +      74,   201,    71,    81,    81,    81,    71,    74,    76,    73,
  1.1154 +     267,    71,    73,   275,   250,    40,    75,    71,    74,    74,
  1.1155 +      78,    74,   284,   161,    74,    71,    16,    72,    76,    81,
  1.1156 +      72,   201,   294,   255,    81,   191,    80,   173,   192,    59,
  1.1157 +     297,   193,   212,   181,   182,   183,   184,   185,   186,   187,
  1.1158 +     188,   189,   190,   191,   192,   193,    85,    66,    85,     5,
  1.1159 +     130,   295,   257,   212,   251,   257,   275,    46,    -1,    -1,
  1.1160 +      -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,
  1.1161 +      -1,    -1,    -1,    -1,   278,   223,   256,   257,    -1,    -1,
  1.1162 +     260,   261,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,
  1.1163 +      -1,    -1,    -1,    -1,    -1,   275,    -1,    -1,    -1,    -1,
  1.1164 +      -1,    -1,   250,    -1,    -1,    -1,    -1,    -1,    -1,    -1,
  1.1165 +      -1,   291,    -1,    -1,    -1,   295,     3,     4,     5,     6,
  1.1166 +       7,     8,     9,    10,    11,    12,    13,    14,    15,    -1,
  1.1167 +      17,    18,    19,    20,    21,    22,    23,    24,    25,    26,
  1.1168 +      27,    28,    29,    30,    31,    32,    -1,    -1,    -1,    36,
  1.1169 +      37,    38,    39,    40,    41,    42,    43,    44,    45,    46,
  1.1170 +      47,    48,    49,    -1,    -1,    52,    53,    -1,    -1,    -1,
  1.1171 +      -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,
  1.1172 +      -1,    -1,    -1,    -1,    71,    -1,    -1,    -1,    75,    76,
  1.1173 +      -1,    -1,    -1,    -1,    81,    82,    83,    -1,    85,     3,
  1.1174 +       4,     5,     6,     7,     8,     9,    10,    11,    12,    13,
  1.1175 +      14,    15,    -1,    17,    18,    19,    20,    21,    22,    23,
  1.1176 +      24,    25,    26,    27,    28,    29,    30,    31,    32,    -1,
  1.1177 +      -1,    -1,    36,    37,    38,    39,    40,    41,    42,    43,
  1.1178 +      44,    45,    46,    47,    48,    49,    -1,    -1,    52,    53,
  1.1179 +      -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,
  1.1180 +      -1,    -1,    -1,    -1,    -1,    -1,    -1,    71,    -1,    -1,
  1.1181 +      -1,    75,    76,    -1,    -1,    -1,    -1,    81,    82,    83,
  1.1182 +      -1,    85,     3,     4,     5,     6,     7,     8,     9,    10,
  1.1183 +      11,    12,    13,    14,    15,    -1,    17,    18,    19,    20,
  1.1184 +      21,    22,    23,    24,    25,    26,    27,    28,    29,    30,
  1.1185 +      31,    32,    -1,    -1,    -1,    36,    37,    38,    39,    40,
  1.1186 +      41,    42,    43,    44,    45,    46,    47,    48,    49,    -1,
  1.1187 +      -1,    52,    53,    -1,    -1,    -1,    -1,    -1,    -1,    -1,
  1.1188 +      -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,
  1.1189 +      71,    -1,    -1,    -1,    75,    -1,    -1,    -1,    -1,    -1,
  1.1190 +      81,    82,    83,    -1,    85,     3,     4,     5,     6,     7,
  1.1191 +       8,     9,    10,    11,    12,    13,    14,    15,    -1,    17,
  1.1192 +      18,    19,    20,    21,    22,    23,    24,    25,    26,    27,
  1.1193 +      28,    29,    30,    31,    32,    -1,    -1,    -1,    36,    37,
  1.1194 +      38,    39,    40,    41,    42,    43,    44,    45,    46,    47,
  1.1195 +      48,    49,    -1,    -1,    52,    53,    -1,    -1,    -1,    -1,
  1.1196 +      -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,
  1.1197 +      -1,    -1,    -1,    71,    -1,    -1,    -1,    75,    -1,    -1,
  1.1198 +      -1,    -1,    -1,    81,    82,    83,    -1,    85,     3,     4,
  1.1199 +       5,     6,     7,     8,     9,    10,    11,    12,    13,    14,
  1.1200 +      15,    -1,    17,    18,    19,    20,    21,    22,    23,    24,
  1.1201 +      25,    26,    27,    28,    29,    30,    31,    32,    -1,    -1,
  1.1202 +      -1,    36,    37,    38,    39,    40,    41,    42,    43,    44,
  1.1203 +      45,    46,    47,    48,    49,    -1,    -1,    52,    53,    -1,
  1.1204 +      -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,
  1.1205 +      -1,    -1,    -1,    -1,    -1,    -1,    71,    -1,    -1,    -1,
  1.1206 +      -1,    -1,    -1,    -1,    -1,    -1,    81,    82,    83,    -1,
  1.1207 +      85,     3,     4,     5,     6,     7,     8,     9,    10,    11,
  1.1208 +      12,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    21,
  1.1209 +      22,    23,    24,    25,    26,    27,    28,    29,    30,    31,
  1.1210 +      32,    -1,    -1,    -1,    36,    37,    38,    39,    -1,    41,
  1.1211 +      42,    43,    44,    45,    46,    47,    48,    49,    -1,    -1,
  1.1212 +      52,    53,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,
  1.1213 +      -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    71,
  1.1214 +      -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    81,
  1.1215 +      82,    83,    -1,    85,     3,     4,     5,     6,    -1,     8,
  1.1216 +       9,    10,    11,    12,    -1,    -1,    -1,    -1,    -1,    -1,
  1.1217 +      -1,    -1,    21,    22,    23,    24,    25,    26,    27,    28,
  1.1218 +      29,    30,    31,    32,    -1,    -1,    -1,    36,    37,    38,
  1.1219 +      39,    -1,    41,    42,    43,    44,    45,    46,    47,    48,
  1.1220 +      49,    -1,    -1,    52,    53,    -1,    -1,    -1,    -1,    -1,
  1.1221 +      -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,
  1.1222 +      -1,    -1,    71,    -1,    -1,    -1,    10,    11,    12,    -1,
  1.1223 +      -1,    -1,    -1,    82,    83,    -1,    85,    21,    22,    23,
  1.1224 +      24,    25,    26,    27,    28,    29,    30,    31,    32,    -1,
  1.1225 +      -1,    -1,    -1,    -1,    38,    39,    -1,    41,    42,    43,
  1.1226 +      44,    45,    46,    47,    48,    49,    -1,    -1,    52,    53,
  1.1227 +      -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,
  1.1228 +      -1,    -1,    -1,    -1,    -1,    -1,    -1,    71,    -1,    -1,
  1.1229 +      74,    10,    11,    12,    -1,    -1,    -1,    -1,    82,    83,
  1.1230 +      -1,    85,    21,    22,    23,    24,    25,    26,    27,    28,
  1.1231 +      29,    30,    31,    32,    -1,    -1,    -1,    -1,    -1,    38,
  1.1232 +      39,    -1,    41,    42,    43,    44,    45,    46,    47,    48,
  1.1233 +      49,    -1,    -1,    52,    53,    -1,    -1,    -1,    -1,    -1,
  1.1234 +      -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,
  1.1235 +      -1,    -1,    71,    -1,    -1,    -1,    10,    11,    12,    -1,
  1.1236 +      -1,    -1,    81,    82,    83,    -1,    85,    21,    22,    23,
  1.1237 +      24,    25,    26,    27,    28,    29,    30,    31,    32,    -1,
  1.1238 +      -1,    -1,    -1,    -1,    38,    39,    -1,    41,    42,    43,
  1.1239 +      44,    45,    46,    47,    48,    49,    -1,    -1,    52,    53,
  1.1240 +      -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,
  1.1241 +      -1,    -1,    -1,    -1,    -1,    -1,    -1,    71,    -1,    -1,
  1.1242 +      74,    10,    11,    12,    -1,    -1,    -1,    -1,    82,    83,
  1.1243 +      -1,    85,    21,    22,    23,    24,    25,    26,    27,    28,
  1.1244 +      29,    30,    31,    32,    -1,    -1,    -1,    -1,    -1,    38,
  1.1245 +      39,    -1,    41,    42,    43,    44,    45,    46,    47,    48,
  1.1246 +      49,    -1,    -1,    52,    53,    -1,    -1,    -1,    -1,    -1,
  1.1247 +      -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,
  1.1248 +      -1,    -1,    71,    -1,    -1,    -1,    10,    11,    12,    -1,
  1.1249 +      -1,    -1,    -1,    82,    83,    -1,    85,    21,    22,    23,
  1.1250 +      24,    25,    26,    27,    28,    29,    30,    31,    32,    -1,
  1.1251 +      -1,    -1,    -1,    -1,    38,    39,    -1,    41,    42,    43,
  1.1252 +      44,    45,    46,    47,    48,    49,    -1,    -1,    52,    53,
  1.1253 +      -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,
  1.1254 +      -1,    -1,    -1,    -1,    -1,    -1,    -1,    71,     4,     5,
  1.1255 +       6,    -1,    -1,    -1,    10,    11,    12,    -1,    82,    83,
  1.1256 +      -1,    85,    -1,    -1,    -1,    21,    22,    23,    24,    25,
  1.1257 +      26,    27,    28,    29,    30,    31,    32,    -1,    -1,    -1,
  1.1258 +      -1,    -1,    38,    39,    -1,    41,    42,    43,    44,    -1,
  1.1259 +      46,     4,     5,     6,    -1,    -1,    -1,    10,    11,    12,
  1.1260 +      -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    21,    22,
  1.1261 +      23,    24,    25,    26,    27,    28,    29,    30,    31,    32,
  1.1262 +      76,    -1,    -1,    -1,    -1,    38,    39,    -1,    41,    42,
  1.1263 +      43,    44,    -1,    46,    -1,    -1,    -1,    -1,    -1,    -1,
  1.1264 +      -1,    -1,    -1,     0,    -1,    -1,     3,     4,     5,     6,
  1.1265 +       7,     8,     9,    10,    11,    12,    -1,    -1,    -1,    -1,
  1.1266 +      -1,    -1,    -1,    76,    21,    22,    23,    24,    25,    26,
  1.1267 +      27,    28,    29,    30,    31,    32,    -1,    -1,    -1,    36,
  1.1268 +      37,    38,    39,    -1,    41,    42,    43,    44,    -1,    46,
  1.1269 +       3,     4,     5,     6,     7,     8,     9,    10,    11,    12,
  1.1270 +      -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    21,    22,
  1.1271 +      23,    24,    25,    26,    27,    28,    29,    30,    31,    32,
  1.1272 +      -1,    -1,    -1,    36,    37,    38,    39,    -1,    41,    42,
  1.1273 +      43,    44,    -1,    46,     4,     5,     6,    -1,    -1,    -1,
  1.1274 +      10,    11,    12,    -1,    -1,    -1,    -1,    -1,    -1,    -1,
  1.1275 +      -1,    21,    22,    23,    24,    25,    26,    27,    28,    29,
  1.1276 +      30,    31,    32,    -1,    -1,    -1,    -1,    -1,    38,    39,
  1.1277 +      -1,    41,    42,    43,    44,    -1,    46,    10,    11,    12,
  1.1278 +      -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    21,    22,
  1.1279 +      23,    24,    25,    26,    27,    28,    29,    30,    31,    32,
  1.1280 +      -1,    -1,    -1,    -1,    -1,    38,    39,    -1,    41,    42,
  1.1281 +      43,    44,    45,    46,    10,    11,    12,    -1,    -1,    -1,
  1.1282 +      -1,    -1,    -1,    -1,    -1,    21,    22,    23,    24,    25,
  1.1283 +      26,    27,    28,    29,    30,    31,    32,    -1,    -1,    -1,
  1.1284 +      -1,    -1,    38,    39,    -1,    41,    42,    43,    44,    -1,
  1.1285 +      46
  1.1286 +};
  1.1287 +
  1.1288 +/* YYSTOS[STATE-NUM] -- The (internal number of the) accessing
  1.1289 +   symbol of state STATE-NUM.  */
  1.1290 +static const yytype_uint8 yystos[] =
  1.1291 +{
  1.1292 +       0,     3,     4,     5,     6,     7,     8,     9,    10,    11,
  1.1293 +      12,    21,    22,    23,    24,    25,    26,    27,    28,    29,
  1.1294 +      30,    31,    32,    36,    37,    38,    39,    41,    42,    43,
  1.1295 +      44,    46,   126,   127,   128,   129,   130,   135,   136,   137,
  1.1296 +     138,   139,   140,   141,   142,   143,   175,   176,   177,    37,
  1.1297 +      45,   140,    45,    46,    75,    96,    81,   178,    72,    78,
  1.1298 +       3,    33,    34,    35,   132,   133,   138,    78,    81,    45,
  1.1299 +      96,   139,   141,    73,     0,   176,   141,   145,    75,    75,
  1.1300 +     161,   132,   131,   134,   139,   133,    96,    71,    73,    80,
  1.1301 +      45,    47,    48,    49,    52,    53,    71,    82,    83,    85,
  1.1302 +      97,    98,    99,   101,   102,   103,   104,   105,   106,   107,
  1.1303 +     108,   109,   110,   111,   112,   113,   114,   115,   116,   117,
  1.1304 +     118,   119,   120,   121,   125,   142,    81,   139,   146,   147,
  1.1305 +     144,    13,    14,    15,    17,    18,    19,    20,    40,    75,
  1.1306 +      76,    81,   108,   121,   122,   124,   126,   127,   142,   151,
  1.1307 +     152,   153,   154,   162,   163,   164,   167,   174,    96,   131,
  1.1308 +     134,    73,    80,    74,   125,   122,   150,   108,   108,   124,
  1.1309 +      52,    53,    73,    77,    72,    72,    78,    39,   122,    71,
  1.1310 +     108,    86,    87,    83,    85,    54,    55,    89,    90,    56,
  1.1311 +      57,    58,    60,    59,    94,    74,    96,   148,   149,    76,
  1.1312 +     147,   146,    81,    81,   169,    71,    71,    81,    81,   124,
  1.1313 +      71,    76,   155,    61,    62,    63,    70,    80,   123,    78,
  1.1314 +      81,    76,   152,    73,    74,   125,   150,    74,    72,   100,
  1.1315 +     124,    45,    46,    96,   103,   122,   108,   108,   110,   110,
  1.1316 +     112,   112,   112,   112,   113,   113,   117,   118,   119,   124,
  1.1317 +      73,    78,    81,    76,   158,   159,   160,   170,   124,    81,
  1.1318 +     168,   162,   122,   122,   125,    74,    74,    79,   125,   149,
  1.1319 +      40,   161,   153,   151,   163,   171,    72,   124,   137,   166,
  1.1320 +     156,    74,   122,    74,    71,   166,   172,   173,   158,   165,
  1.1321 +      96,    72,    76,   124,    81,    72,    16,    80,   153,   157,
  1.1322 +     161,    72,   124,   157,   158,   150,    81
  1.1323 +};
  1.1324 +
  1.1325 +#define yyerrok		(yyerrstatus = 0)
  1.1326 +#define yyclearin	(yychar = YYEMPTY)
  1.1327 +#define YYEMPTY		(-2)
  1.1328 +#define YYEOF		0
  1.1329 +
  1.1330 +#define YYACCEPT	goto yyacceptlab
  1.1331 +#define YYABORT		goto yyabortlab
  1.1332 +#define YYERROR		goto yyerrorlab
  1.1333 +
  1.1334 +
  1.1335 +/* Like YYERROR except do call yyerror.  This remains here temporarily
  1.1336 +   to ease the transition to the new meaning of YYERROR, for GCC.
  1.1337 +   Once GCC version 2 has supplanted version 1, this can go.  However,
  1.1338 +   YYFAIL appears to be in use.  Nevertheless, it is formally deprecated
  1.1339 +   in Bison 2.4.2's NEWS entry, where a plan to phase it out is
  1.1340 +   discussed.  */
  1.1341 +
  1.1342 +#define YYFAIL		goto yyerrlab
  1.1343 +#if defined YYFAIL
  1.1344 +  /* This is here to suppress warnings from the GCC cpp's
  1.1345 +     -Wunused-macros.  Normally we don't worry about that warning, but
  1.1346 +     some users do, and we want to make it easy for users to remove
  1.1347 +     YYFAIL uses, which will produce warnings from Bison 2.5.  */
  1.1348 +#endif
  1.1349 +
  1.1350 +#define YYRECOVERING()  (!!yyerrstatus)
  1.1351 +
  1.1352 +#define YYBACKUP(Token, Value)                                  \
  1.1353 +do                                                              \
  1.1354 +  if (yychar == YYEMPTY)                                        \
  1.1355 +    {                                                           \
  1.1356 +      yychar = (Token);                                         \
  1.1357 +      yylval = (Value);                                         \
  1.1358 +      YYPOPSTACK (yylen);                                       \
  1.1359 +      yystate = *yyssp;                                         \
  1.1360 +      goto yybackup;                                            \
  1.1361 +    }                                                           \
  1.1362 +  else                                                          \
  1.1363 +    {                                                           \
  1.1364 +      yyerror (&yylloc, context, YY_("syntax error: cannot back up")); \
  1.1365 +      YYERROR;							\
  1.1366 +    }								\
  1.1367 +while (YYID (0))
  1.1368 +
  1.1369 +/* Error token number */
  1.1370 +#define YYTERROR	1
  1.1371 +#define YYERRCODE	256
  1.1372 +
  1.1373 +
  1.1374 +/* YYLLOC_DEFAULT -- Set CURRENT to span from RHS[1] to RHS[N].
  1.1375 +   If N is 0, then set CURRENT to the empty location which ends
  1.1376 +   the previous symbol: RHS[0] (always defined).  */
  1.1377 +
  1.1378 +#ifndef YYLLOC_DEFAULT
  1.1379 +# define YYLLOC_DEFAULT(Current, Rhs, N)                                \
  1.1380 +    do                                                                  \
  1.1381 +      if (YYID (N))                                                     \
  1.1382 +        {                                                               \
  1.1383 +          (Current).first_line   = YYRHSLOC (Rhs, 1).first_line;        \
  1.1384 +          (Current).first_column = YYRHSLOC (Rhs, 1).first_column;      \
  1.1385 +          (Current).last_line    = YYRHSLOC (Rhs, N).last_line;         \
  1.1386 +          (Current).last_column  = YYRHSLOC (Rhs, N).last_column;       \
  1.1387 +        }                                                               \
  1.1388 +      else                                                              \
  1.1389 +        {                                                               \
  1.1390 +          (Current).first_line   = (Current).last_line   =              \
  1.1391 +            YYRHSLOC (Rhs, 0).last_line;                                \
  1.1392 +          (Current).first_column = (Current).last_column =              \
  1.1393 +            YYRHSLOC (Rhs, 0).last_column;                              \
  1.1394 +        }                                                               \
  1.1395 +    while (YYID (0))
  1.1396 +#endif
  1.1397 +
  1.1398 +#define YYRHSLOC(Rhs, K) ((Rhs)[K])
  1.1399 +
  1.1400 +
  1.1401 +/* YY_LOCATION_PRINT -- Print the location on the stream.
  1.1402 +   This macro was not mandated originally: define only if we know
  1.1403 +   we won't break user code: when these are the locations we know.  */
  1.1404 +
  1.1405 +#ifndef YY_LOCATION_PRINT
  1.1406 +# if defined YYLTYPE_IS_TRIVIAL && YYLTYPE_IS_TRIVIAL
  1.1407 +
  1.1408 +/* Print *YYLOCP on YYO.  Private, do not rely on its existence. */
  1.1409 +
  1.1410 +__attribute__((__unused__))
  1.1411 +#if (defined __STDC__ || defined __C99__FUNC__ \
  1.1412 +     || defined __cplusplus || defined _MSC_VER)
  1.1413 +static unsigned
  1.1414 +yy_location_print_ (FILE *yyo, YYLTYPE const * const yylocp)
  1.1415 +#else
  1.1416 +static unsigned
  1.1417 +yy_location_print_ (yyo, yylocp)
  1.1418 +    FILE *yyo;
  1.1419 +    YYLTYPE const * const yylocp;
  1.1420 +#endif
  1.1421 +{
  1.1422 +  unsigned res = 0;
  1.1423 +  int end_col = 0 != yylocp->last_column ? yylocp->last_column - 1 : 0;
  1.1424 +  if (0 <= yylocp->first_line)
  1.1425 +    {
  1.1426 +      res += fprintf (yyo, "%d", yylocp->first_line);
  1.1427 +      if (0 <= yylocp->first_column)
  1.1428 +        res += fprintf (yyo, ".%d", yylocp->first_column);
  1.1429 +    }
  1.1430 +  if (0 <= yylocp->last_line)
  1.1431 +    {
  1.1432 +      if (yylocp->first_line < yylocp->last_line)
  1.1433 +        {
  1.1434 +          res += fprintf (yyo, "-%d", yylocp->last_line);
  1.1435 +          if (0 <= end_col)
  1.1436 +            res += fprintf (yyo, ".%d", end_col);
  1.1437 +        }
  1.1438 +      else if (0 <= end_col && yylocp->first_column < end_col)
  1.1439 +        res += fprintf (yyo, "-%d", end_col);
  1.1440 +    }
  1.1441 +  return res;
  1.1442 + }
  1.1443 +
  1.1444 +#  define YY_LOCATION_PRINT(File, Loc)          \
  1.1445 +  yy_location_print_ (File, &(Loc))
  1.1446 +
  1.1447 +# else
  1.1448 +#  define YY_LOCATION_PRINT(File, Loc) ((void) 0)
  1.1449 +# endif
  1.1450 +#endif
  1.1451 +
  1.1452 +
  1.1453 +/* YYLEX -- calling `yylex' with the right arguments.  */
  1.1454 +#ifdef YYLEX_PARAM
  1.1455 +# define YYLEX yylex (&yylval, &yylloc, YYLEX_PARAM)
  1.1456 +#else
  1.1457 +# define YYLEX yylex (&yylval, &yylloc)
  1.1458 +#endif
  1.1459 +
  1.1460 +/* Enable debugging if requested.  */
  1.1461 +#if YYDEBUG
  1.1462 +
  1.1463 +# ifndef YYFPRINTF
  1.1464 +#  include <stdio.h> /* INFRINGES ON USER NAME SPACE */
  1.1465 +#  define YYFPRINTF fprintf
  1.1466 +# endif
  1.1467 +
  1.1468 +# define YYDPRINTF(Args)			\
  1.1469 +do {						\
  1.1470 +  if (yydebug)					\
  1.1471 +    YYFPRINTF Args;				\
  1.1472 +} while (YYID (0))
  1.1473 +
  1.1474 +# define YY_SYMBOL_PRINT(Title, Type, Value, Location)			  \
  1.1475 +do {									  \
  1.1476 +  if (yydebug)								  \
  1.1477 +    {									  \
  1.1478 +      YYFPRINTF (stderr, "%s ", Title);					  \
  1.1479 +      yy_symbol_print (stderr,						  \
  1.1480 +		  Type, Value, Location, context); \
  1.1481 +      YYFPRINTF (stderr, "\n");						  \
  1.1482 +    }									  \
  1.1483 +} while (YYID (0))
  1.1484 +
  1.1485 +
  1.1486 +/*--------------------------------.
  1.1487 +| Print this symbol on YYOUTPUT.  |
  1.1488 +`--------------------------------*/
  1.1489 +
  1.1490 +/*ARGSUSED*/
  1.1491 +#if (defined __STDC__ || defined __C99__FUNC__ \
  1.1492 +     || defined __cplusplus || defined _MSC_VER)
  1.1493 +static void
  1.1494 +yy_symbol_value_print (FILE *yyoutput, int yytype, YYSTYPE const * const yyvaluep, YYLTYPE const * const yylocationp, TParseContext* context)
  1.1495 +#else
  1.1496 +static void
  1.1497 +yy_symbol_value_print (yyoutput, yytype, yyvaluep, yylocationp, context)
  1.1498 +    FILE *yyoutput;
  1.1499 +    int yytype;
  1.1500 +    YYSTYPE const * const yyvaluep;
  1.1501 +    YYLTYPE const * const yylocationp;
  1.1502 +    TParseContext* context;
  1.1503 +#endif
  1.1504 +{
  1.1505 +  FILE *yyo = yyoutput;
  1.1506 +  YYUSE (yyo);
  1.1507 +  if (!yyvaluep)
  1.1508 +    return;
  1.1509 +  YYUSE (yylocationp);
  1.1510 +  YYUSE (context);
  1.1511 +# ifdef YYPRINT
  1.1512 +  if (yytype < YYNTOKENS)
  1.1513 +    YYPRINT (yyoutput, yytoknum[yytype], *yyvaluep);
  1.1514 +# else
  1.1515 +  YYUSE (yyoutput);
  1.1516 +# endif
  1.1517 +  switch (yytype)
  1.1518 +    {
  1.1519 +      default:
  1.1520 +        break;
  1.1521 +    }
  1.1522 +}
  1.1523 +
  1.1524 +
  1.1525 +/*--------------------------------.
  1.1526 +| Print this symbol on YYOUTPUT.  |
  1.1527 +`--------------------------------*/
  1.1528 +
  1.1529 +#if (defined __STDC__ || defined __C99__FUNC__ \
  1.1530 +     || defined __cplusplus || defined _MSC_VER)
  1.1531 +static void
  1.1532 +yy_symbol_print (FILE *yyoutput, int yytype, YYSTYPE const * const yyvaluep, YYLTYPE const * const yylocationp, TParseContext* context)
  1.1533 +#else
  1.1534 +static void
  1.1535 +yy_symbol_print (yyoutput, yytype, yyvaluep, yylocationp, context)
  1.1536 +    FILE *yyoutput;
  1.1537 +    int yytype;
  1.1538 +    YYSTYPE const * const yyvaluep;
  1.1539 +    YYLTYPE const * const yylocationp;
  1.1540 +    TParseContext* context;
  1.1541 +#endif
  1.1542 +{
  1.1543 +  if (yytype < YYNTOKENS)
  1.1544 +    YYFPRINTF (yyoutput, "token %s (", yytname[yytype]);
  1.1545 +  else
  1.1546 +    YYFPRINTF (yyoutput, "nterm %s (", yytname[yytype]);
  1.1547 +
  1.1548 +  YY_LOCATION_PRINT (yyoutput, *yylocationp);
  1.1549 +  YYFPRINTF (yyoutput, ": ");
  1.1550 +  yy_symbol_value_print (yyoutput, yytype, yyvaluep, yylocationp, context);
  1.1551 +  YYFPRINTF (yyoutput, ")");
  1.1552 +}
  1.1553 +
  1.1554 +/*------------------------------------------------------------------.
  1.1555 +| yy_stack_print -- Print the state stack from its BOTTOM up to its |
  1.1556 +| TOP (included).                                                   |
  1.1557 +`------------------------------------------------------------------*/
  1.1558 +
  1.1559 +#if (defined __STDC__ || defined __C99__FUNC__ \
  1.1560 +     || defined __cplusplus || defined _MSC_VER)
  1.1561 +static void
  1.1562 +yy_stack_print (yytype_int16 *yybottom, yytype_int16 *yytop)
  1.1563 +#else
  1.1564 +static void
  1.1565 +yy_stack_print (yybottom, yytop)
  1.1566 +    yytype_int16 *yybottom;
  1.1567 +    yytype_int16 *yytop;
  1.1568 +#endif
  1.1569 +{
  1.1570 +  YYFPRINTF (stderr, "Stack now");
  1.1571 +  for (; yybottom <= yytop; yybottom++)
  1.1572 +    {
  1.1573 +      int yybot = *yybottom;
  1.1574 +      YYFPRINTF (stderr, " %d", yybot);
  1.1575 +    }
  1.1576 +  YYFPRINTF (stderr, "\n");
  1.1577 +}
  1.1578 +
  1.1579 +# define YY_STACK_PRINT(Bottom, Top)				\
  1.1580 +do {								\
  1.1581 +  if (yydebug)							\
  1.1582 +    yy_stack_print ((Bottom), (Top));				\
  1.1583 +} while (YYID (0))
  1.1584 +
  1.1585 +
  1.1586 +/*------------------------------------------------.
  1.1587 +| Report that the YYRULE is going to be reduced.  |
  1.1588 +`------------------------------------------------*/
  1.1589 +
  1.1590 +#if (defined __STDC__ || defined __C99__FUNC__ \
  1.1591 +     || defined __cplusplus || defined _MSC_VER)
  1.1592 +static void
  1.1593 +yy_reduce_print (YYSTYPE *yyvsp, YYLTYPE *yylsp, int yyrule, TParseContext* context)
  1.1594 +#else
  1.1595 +static void
  1.1596 +yy_reduce_print (yyvsp, yylsp, yyrule, context)
  1.1597 +    YYSTYPE *yyvsp;
  1.1598 +    YYLTYPE *yylsp;
  1.1599 +    int yyrule;
  1.1600 +    TParseContext* context;
  1.1601 +#endif
  1.1602 +{
  1.1603 +  int yynrhs = yyr2[yyrule];
  1.1604 +  int yyi;
  1.1605 +  unsigned long int yylno = yyrline[yyrule];
  1.1606 +  YYFPRINTF (stderr, "Reducing stack by rule %d (line %lu):\n",
  1.1607 +	     yyrule - 1, yylno);
  1.1608 +  /* The symbols being reduced.  */
  1.1609 +  for (yyi = 0; yyi < yynrhs; yyi++)
  1.1610 +    {
  1.1611 +      YYFPRINTF (stderr, "   $%d = ", yyi + 1);
  1.1612 +      yy_symbol_print (stderr, yyrhs[yyprhs[yyrule] + yyi],
  1.1613 +		       &(yyvsp[(yyi + 1) - (yynrhs)])
  1.1614 +		       , &(yylsp[(yyi + 1) - (yynrhs)])		       , context);
  1.1615 +      YYFPRINTF (stderr, "\n");
  1.1616 +    }
  1.1617 +}
  1.1618 +
  1.1619 +# define YY_REDUCE_PRINT(Rule)		\
  1.1620 +do {					\
  1.1621 +  if (yydebug)				\
  1.1622 +    yy_reduce_print (yyvsp, yylsp, Rule, context); \
  1.1623 +} while (YYID (0))
  1.1624 +
  1.1625 +/* Nonzero means print parse trace.  It is left uninitialized so that
  1.1626 +   multiple parsers can coexist.  */
  1.1627 +int yydebug;
  1.1628 +#else /* !YYDEBUG */
  1.1629 +# define YYDPRINTF(Args)
  1.1630 +# define YY_SYMBOL_PRINT(Title, Type, Value, Location)
  1.1631 +# define YY_STACK_PRINT(Bottom, Top)
  1.1632 +# define YY_REDUCE_PRINT(Rule)
  1.1633 +#endif /* !YYDEBUG */
  1.1634 +
  1.1635 +
  1.1636 +/* YYINITDEPTH -- initial size of the parser's stacks.  */
  1.1637 +#ifndef	YYINITDEPTH
  1.1638 +# define YYINITDEPTH 200
  1.1639 +#endif
  1.1640 +
  1.1641 +/* YYMAXDEPTH -- maximum size the stacks can grow to (effective only
  1.1642 +   if the built-in stack extension method is used).
  1.1643 +
  1.1644 +   Do not make this value too large; the results are undefined if
  1.1645 +   YYSTACK_ALLOC_MAXIMUM < YYSTACK_BYTES (YYMAXDEPTH)
  1.1646 +   evaluated with infinite-precision integer arithmetic.  */
  1.1647 +
  1.1648 +#ifndef YYMAXDEPTH
  1.1649 +# define YYMAXDEPTH 10000
  1.1650 +#endif
  1.1651 +
  1.1652 +
  1.1653 +#if YYERROR_VERBOSE
  1.1654 +
  1.1655 +# ifndef yystrlen
  1.1656 +#  if defined __GLIBC__ && defined _STRING_H
  1.1657 +#   define yystrlen strlen
  1.1658 +#  else
  1.1659 +/* Return the length of YYSTR.  */
  1.1660 +#if (defined __STDC__ || defined __C99__FUNC__ \
  1.1661 +     || defined __cplusplus || defined _MSC_VER)
  1.1662 +static YYSIZE_T
  1.1663 +yystrlen (const char *yystr)
  1.1664 +#else
  1.1665 +static YYSIZE_T
  1.1666 +yystrlen (yystr)
  1.1667 +    const char *yystr;
  1.1668 +#endif
  1.1669 +{
  1.1670 +  YYSIZE_T yylen;
  1.1671 +  for (yylen = 0; yystr[yylen]; yylen++)
  1.1672 +    continue;
  1.1673 +  return yylen;
  1.1674 +}
  1.1675 +#  endif
  1.1676 +# endif
  1.1677 +
  1.1678 +# ifndef yystpcpy
  1.1679 +#  if defined __GLIBC__ && defined _STRING_H && defined _GNU_SOURCE
  1.1680 +#   define yystpcpy stpcpy
  1.1681 +#  else
  1.1682 +/* Copy YYSRC to YYDEST, returning the address of the terminating '\0' in
  1.1683 +   YYDEST.  */
  1.1684 +#if (defined __STDC__ || defined __C99__FUNC__ \
  1.1685 +     || defined __cplusplus || defined _MSC_VER)
  1.1686 +static char *
  1.1687 +yystpcpy (char *yydest, const char *yysrc)
  1.1688 +#else
  1.1689 +static char *
  1.1690 +yystpcpy (yydest, yysrc)
  1.1691 +    char *yydest;
  1.1692 +    const char *yysrc;
  1.1693 +#endif
  1.1694 +{
  1.1695 +  char *yyd = yydest;
  1.1696 +  const char *yys = yysrc;
  1.1697 +
  1.1698 +  while ((*yyd++ = *yys++) != '\0')
  1.1699 +    continue;
  1.1700 +
  1.1701 +  return yyd - 1;
  1.1702 +}
  1.1703 +#  endif
  1.1704 +# endif
  1.1705 +
  1.1706 +# ifndef yytnamerr
  1.1707 +/* Copy to YYRES the contents of YYSTR after stripping away unnecessary
  1.1708 +   quotes and backslashes, so that it's suitable for yyerror.  The
  1.1709 +   heuristic is that double-quoting is unnecessary unless the string
  1.1710 +   contains an apostrophe, a comma, or backslash (other than
  1.1711 +   backslash-backslash).  YYSTR is taken from yytname.  If YYRES is
  1.1712 +   null, do not copy; instead, return the length of what the result
  1.1713 +   would have been.  */
  1.1714 +static YYSIZE_T
  1.1715 +yytnamerr (char *yyres, const char *yystr)
  1.1716 +{
  1.1717 +  if (*yystr == '"')
  1.1718 +    {
  1.1719 +      YYSIZE_T yyn = 0;
  1.1720 +      char const *yyp = yystr;
  1.1721 +
  1.1722 +      for (;;)
  1.1723 +	switch (*++yyp)
  1.1724 +	  {
  1.1725 +	  case '\'':
  1.1726 +	  case ',':
  1.1727 +	    goto do_not_strip_quotes;
  1.1728 +
  1.1729 +	  case '\\':
  1.1730 +	    if (*++yyp != '\\')
  1.1731 +	      goto do_not_strip_quotes;
  1.1732 +	    /* Fall through.  */
  1.1733 +	  default:
  1.1734 +	    if (yyres)
  1.1735 +	      yyres[yyn] = *yyp;
  1.1736 +	    yyn++;
  1.1737 +	    break;
  1.1738 +
  1.1739 +	  case '"':
  1.1740 +	    if (yyres)
  1.1741 +	      yyres[yyn] = '\0';
  1.1742 +	    return yyn;
  1.1743 +	  }
  1.1744 +    do_not_strip_quotes: ;
  1.1745 +    }
  1.1746 +
  1.1747 +  if (! yyres)
  1.1748 +    return yystrlen (yystr);
  1.1749 +
  1.1750 +  return yystpcpy (yyres, yystr) - yyres;
  1.1751 +}
  1.1752 +# endif
  1.1753 +
  1.1754 +/* Copy into *YYMSG, which is of size *YYMSG_ALLOC, an error message
  1.1755 +   about the unexpected token YYTOKEN for the state stack whose top is
  1.1756 +   YYSSP.
  1.1757 +
  1.1758 +   Return 0 if *YYMSG was successfully written.  Return 1 if *YYMSG is
  1.1759 +   not large enough to hold the message.  In that case, also set
  1.1760 +   *YYMSG_ALLOC to the required number of bytes.  Return 2 if the
  1.1761 +   required number of bytes is too large to store.  */
  1.1762 +static int
  1.1763 +yysyntax_error (YYSIZE_T *yymsg_alloc, char **yymsg,
  1.1764 +                yytype_int16 *yyssp, int yytoken)
  1.1765 +{
  1.1766 +  YYSIZE_T yysize0 = yytnamerr (YY_NULL, yytname[yytoken]);
  1.1767 +  YYSIZE_T yysize = yysize0;
  1.1768 +  enum { YYERROR_VERBOSE_ARGS_MAXIMUM = 5 };
  1.1769 +  /* Internationalized format string. */
  1.1770 +  const char *yyformat = YY_NULL;
  1.1771 +  /* Arguments of yyformat. */
  1.1772 +  char const *yyarg[YYERROR_VERBOSE_ARGS_MAXIMUM];
  1.1773 +  /* Number of reported tokens (one for the "unexpected", one per
  1.1774 +     "expected"). */
  1.1775 +  int yycount = 0;
  1.1776 +
  1.1777 +  /* There are many possibilities here to consider:
  1.1778 +     - Assume YYFAIL is not used.  It's too flawed to consider.  See
  1.1779 +       <http://lists.gnu.org/archive/html/bison-patches/2009-12/msg00024.html>
  1.1780 +       for details.  YYERROR is fine as it does not invoke this
  1.1781 +       function.
  1.1782 +     - If this state is a consistent state with a default action, then
  1.1783 +       the only way this function was invoked is if the default action
  1.1784 +       is an error action.  In that case, don't check for expected
  1.1785 +       tokens because there are none.
  1.1786 +     - The only way there can be no lookahead present (in yychar) is if
  1.1787 +       this state is a consistent state with a default action.  Thus,
  1.1788 +       detecting the absence of a lookahead is sufficient to determine
  1.1789 +       that there is no unexpected or expected token to report.  In that
  1.1790 +       case, just report a simple "syntax error".
  1.1791 +     - Don't assume there isn't a lookahead just because this state is a
  1.1792 +       consistent state with a default action.  There might have been a
  1.1793 +       previous inconsistent state, consistent state with a non-default
  1.1794 +       action, or user semantic action that manipulated yychar.
  1.1795 +     - Of course, the expected token list depends on states to have
  1.1796 +       correct lookahead information, and it depends on the parser not
  1.1797 +       to perform extra reductions after fetching a lookahead from the
  1.1798 +       scanner and before detecting a syntax error.  Thus, state merging
  1.1799 +       (from LALR or IELR) and default reductions corrupt the expected
  1.1800 +       token list.  However, the list is correct for canonical LR with
  1.1801 +       one exception: it will still contain any token that will not be
  1.1802 +       accepted due to an error action in a later state.
  1.1803 +  */
  1.1804 +  if (yytoken != YYEMPTY)
  1.1805 +    {
  1.1806 +      int yyn = yypact[*yyssp];
  1.1807 +      yyarg[yycount++] = yytname[yytoken];
  1.1808 +      if (!yypact_value_is_default (yyn))
  1.1809 +        {
  1.1810 +          /* Start YYX at -YYN if negative to avoid negative indexes in
  1.1811 +             YYCHECK.  In other words, skip the first -YYN actions for
  1.1812 +             this state because they are default actions.  */
  1.1813 +          int yyxbegin = yyn < 0 ? -yyn : 0;
  1.1814 +          /* Stay within bounds of both yycheck and yytname.  */
  1.1815 +          int yychecklim = YYLAST - yyn + 1;
  1.1816 +          int yyxend = yychecklim < YYNTOKENS ? yychecklim : YYNTOKENS;
  1.1817 +          int yyx;
  1.1818 +
  1.1819 +          for (yyx = yyxbegin; yyx < yyxend; ++yyx)
  1.1820 +            if (yycheck[yyx + yyn] == yyx && yyx != YYTERROR
  1.1821 +                && !yytable_value_is_error (yytable[yyx + yyn]))
  1.1822 +              {
  1.1823 +                if (yycount == YYERROR_VERBOSE_ARGS_MAXIMUM)
  1.1824 +                  {
  1.1825 +                    yycount = 1;
  1.1826 +                    yysize = yysize0;
  1.1827 +                    break;
  1.1828 +                  }
  1.1829 +                yyarg[yycount++] = yytname[yyx];
  1.1830 +                {
  1.1831 +                  YYSIZE_T yysize1 = yysize + yytnamerr (YY_NULL, yytname[yyx]);
  1.1832 +                  if (! (yysize <= yysize1
  1.1833 +                         && yysize1 <= YYSTACK_ALLOC_MAXIMUM))
  1.1834 +                    return 2;
  1.1835 +                  yysize = yysize1;
  1.1836 +                }
  1.1837 +              }
  1.1838 +        }
  1.1839 +    }
  1.1840 +
  1.1841 +  switch (yycount)
  1.1842 +    {
  1.1843 +# define YYCASE_(N, S)                      \
  1.1844 +      case N:                               \
  1.1845 +        yyformat = S;                       \
  1.1846 +      break
  1.1847 +      YYCASE_(0, YY_("syntax error"));
  1.1848 +      YYCASE_(1, YY_("syntax error, unexpected %s"));
  1.1849 +      YYCASE_(2, YY_("syntax error, unexpected %s, expecting %s"));
  1.1850 +      YYCASE_(3, YY_("syntax error, unexpected %s, expecting %s or %s"));
  1.1851 +      YYCASE_(4, YY_("syntax error, unexpected %s, expecting %s or %s or %s"));
  1.1852 +      YYCASE_(5, YY_("syntax error, unexpected %s, expecting %s or %s or %s or %s"));
  1.1853 +# undef YYCASE_
  1.1854 +    }
  1.1855 +
  1.1856 +  {
  1.1857 +    YYSIZE_T yysize1 = yysize + yystrlen (yyformat);
  1.1858 +    if (! (yysize <= yysize1 && yysize1 <= YYSTACK_ALLOC_MAXIMUM))
  1.1859 +      return 2;
  1.1860 +    yysize = yysize1;
  1.1861 +  }
  1.1862 +
  1.1863 +  if (*yymsg_alloc < yysize)
  1.1864 +    {
  1.1865 +      *yymsg_alloc = 2 * yysize;
  1.1866 +      if (! (yysize <= *yymsg_alloc
  1.1867 +             && *yymsg_alloc <= YYSTACK_ALLOC_MAXIMUM))
  1.1868 +        *yymsg_alloc = YYSTACK_ALLOC_MAXIMUM;
  1.1869 +      return 1;
  1.1870 +    }
  1.1871 +
  1.1872 +  /* Avoid sprintf, as that infringes on the user's name space.
  1.1873 +     Don't have undefined behavior even if the translation
  1.1874 +     produced a string with the wrong number of "%s"s.  */
  1.1875 +  {
  1.1876 +    char *yyp = *yymsg;
  1.1877 +    int yyi = 0;
  1.1878 +    while ((*yyp = *yyformat) != '\0')
  1.1879 +      if (*yyp == '%' && yyformat[1] == 's' && yyi < yycount)
  1.1880 +        {
  1.1881 +          yyp += yytnamerr (yyp, yyarg[yyi++]);
  1.1882 +          yyformat += 2;
  1.1883 +        }
  1.1884 +      else
  1.1885 +        {
  1.1886 +          yyp++;
  1.1887 +          yyformat++;
  1.1888 +        }
  1.1889 +  }
  1.1890 +  return 0;
  1.1891 +}
  1.1892 +#endif /* YYERROR_VERBOSE */
  1.1893 +
  1.1894 +/*-----------------------------------------------.
  1.1895 +| Release the memory associated to this symbol.  |
  1.1896 +`-----------------------------------------------*/
  1.1897 +
  1.1898 +/*ARGSUSED*/
  1.1899 +#if (defined __STDC__ || defined __C99__FUNC__ \
  1.1900 +     || defined __cplusplus || defined _MSC_VER)
  1.1901 +static void
  1.1902 +yydestruct (const char *yymsg, int yytype, YYSTYPE *yyvaluep, YYLTYPE *yylocationp, TParseContext* context)
  1.1903 +#else
  1.1904 +static void
  1.1905 +yydestruct (yymsg, yytype, yyvaluep, yylocationp, context)
  1.1906 +    const char *yymsg;
  1.1907 +    int yytype;
  1.1908 +    YYSTYPE *yyvaluep;
  1.1909 +    YYLTYPE *yylocationp;
  1.1910 +    TParseContext* context;
  1.1911 +#endif
  1.1912 +{
  1.1913 +  YYUSE (yyvaluep);
  1.1914 +  YYUSE (yylocationp);
  1.1915 +  YYUSE (context);
  1.1916 +
  1.1917 +  if (!yymsg)
  1.1918 +    yymsg = "Deleting";
  1.1919 +  YY_SYMBOL_PRINT (yymsg, yytype, yyvaluep, yylocationp);
  1.1920 +
  1.1921 +  switch (yytype)
  1.1922 +    {
  1.1923 +
  1.1924 +      default:
  1.1925 +        break;
  1.1926 +    }
  1.1927 +}
  1.1928 +
  1.1929 +
  1.1930 +
  1.1931 +
  1.1932 +/*----------.
  1.1933 +| yyparse.  |
  1.1934 +`----------*/
  1.1935 +
  1.1936 +#ifdef YYPARSE_PARAM
  1.1937 +#if (defined __STDC__ || defined __C99__FUNC__ \
  1.1938 +     || defined __cplusplus || defined _MSC_VER)
  1.1939 +int
  1.1940 +yyparse (void *YYPARSE_PARAM)
  1.1941 +#else
  1.1942 +int
  1.1943 +yyparse (YYPARSE_PARAM)
  1.1944 +    void *YYPARSE_PARAM;
  1.1945 +#endif
  1.1946 +#else /* ! YYPARSE_PARAM */
  1.1947 +#if (defined __STDC__ || defined __C99__FUNC__ \
  1.1948 +     || defined __cplusplus || defined _MSC_VER)
  1.1949 +int
  1.1950 +yyparse (TParseContext* context)
  1.1951 +#else
  1.1952 +int
  1.1953 +yyparse (context)
  1.1954 +    TParseContext* context;
  1.1955 +#endif
  1.1956 +#endif
  1.1957 +{
  1.1958 +/* The lookahead symbol.  */
  1.1959 +int yychar;
  1.1960 +
  1.1961 +
  1.1962 +#if defined __GNUC__ && 407 <= __GNUC__ * 100 + __GNUC_MINOR__
  1.1963 +/* Suppress an incorrect diagnostic about yylval being uninitialized.  */
  1.1964 +# define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN \
  1.1965 +    _Pragma ("GCC diagnostic push") \
  1.1966 +    _Pragma ("GCC diagnostic ignored \"-Wuninitialized\"")\
  1.1967 +    _Pragma ("GCC diagnostic ignored \"-Wmaybe-uninitialized\"")
  1.1968 +# define YY_IGNORE_MAYBE_UNINITIALIZED_END \
  1.1969 +    _Pragma ("GCC diagnostic pop")
  1.1970 +#else
  1.1971 +/* Default value used for initialization, for pacifying older GCCs
  1.1972 +   or non-GCC compilers.  */
  1.1973 +static YYSTYPE yyval_default;
  1.1974 +# define YY_INITIAL_VALUE(Value) = Value
  1.1975 +#endif
  1.1976 +static YYLTYPE yyloc_default
  1.1977 +# if defined YYLTYPE_IS_TRIVIAL && YYLTYPE_IS_TRIVIAL
  1.1978 +  = { 1, 1, 1, 1 }
  1.1979 +# endif
  1.1980 +;
  1.1981 +#ifndef YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN
  1.1982 +# define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN
  1.1983 +# define YY_IGNORE_MAYBE_UNINITIALIZED_END
  1.1984 +#endif
  1.1985 +#ifndef YY_INITIAL_VALUE
  1.1986 +# define YY_INITIAL_VALUE(Value) /* Nothing. */
  1.1987 +#endif
  1.1988 +
  1.1989 +/* The semantic value of the lookahead symbol.  */
  1.1990 +YYSTYPE yylval YY_INITIAL_VALUE(yyval_default);
  1.1991 +
  1.1992 +/* Location data for the lookahead symbol.  */
  1.1993 +YYLTYPE yylloc = yyloc_default;
  1.1994 +
  1.1995 +
  1.1996 +    /* Number of syntax errors so far.  */
  1.1997 +    int yynerrs;
  1.1998 +
  1.1999 +    int yystate;
  1.2000 +    /* Number of tokens to shift before error messages enabled.  */
  1.2001 +    int yyerrstatus;
  1.2002 +
  1.2003 +    /* The stacks and their tools:
  1.2004 +       `yyss': related to states.
  1.2005 +       `yyvs': related to semantic values.
  1.2006 +       `yyls': related to locations.
  1.2007 +
  1.2008 +       Refer to the stacks through separate pointers, to allow yyoverflow
  1.2009 +       to reallocate them elsewhere.  */
  1.2010 +
  1.2011 +    /* The state stack.  */
  1.2012 +    yytype_int16 yyssa[YYINITDEPTH];
  1.2013 +    yytype_int16 *yyss;
  1.2014 +    yytype_int16 *yyssp;
  1.2015 +
  1.2016 +    /* The semantic value stack.  */
  1.2017 +    YYSTYPE yyvsa[YYINITDEPTH];
  1.2018 +    YYSTYPE *yyvs;
  1.2019 +    YYSTYPE *yyvsp;
  1.2020 +
  1.2021 +    /* The location stack.  */
  1.2022 +    YYLTYPE yylsa[YYINITDEPTH];
  1.2023 +    YYLTYPE *yyls;
  1.2024 +    YYLTYPE *yylsp;
  1.2025 +
  1.2026 +    /* The locations where the error started and ended.  */
  1.2027 +    YYLTYPE yyerror_range[3];
  1.2028 +
  1.2029 +    YYSIZE_T yystacksize;
  1.2030 +
  1.2031 +  int yyn;
  1.2032 +  int yyresult;
  1.2033 +  /* Lookahead token as an internal (translated) token number.  */
  1.2034 +  int yytoken = 0;
  1.2035 +  /* The variables used to return semantic value and location from the
  1.2036 +     action routines.  */
  1.2037 +  YYSTYPE yyval;
  1.2038 +  YYLTYPE yyloc;
  1.2039 +
  1.2040 +#if YYERROR_VERBOSE
  1.2041 +  /* Buffer for error messages, and its allocated size.  */
  1.2042 +  char yymsgbuf[128];
  1.2043 +  char *yymsg = yymsgbuf;
  1.2044 +  YYSIZE_T yymsg_alloc = sizeof yymsgbuf;
  1.2045 +#endif
  1.2046 +
  1.2047 +#define YYPOPSTACK(N)   (yyvsp -= (N), yyssp -= (N), yylsp -= (N))
  1.2048 +
  1.2049 +  /* The number of symbols on the RHS of the reduced rule.
  1.2050 +     Keep to zero when no symbol should be popped.  */
  1.2051 +  int yylen = 0;
  1.2052 +
  1.2053 +  yyssp = yyss = yyssa;
  1.2054 +  yyvsp = yyvs = yyvsa;
  1.2055 +  yylsp = yyls = yylsa;
  1.2056 +  yystacksize = YYINITDEPTH;
  1.2057 +
  1.2058 +  YYDPRINTF ((stderr, "Starting parse\n"));
  1.2059 +
  1.2060 +  yystate = 0;
  1.2061 +  yyerrstatus = 0;
  1.2062 +  yynerrs = 0;
  1.2063 +  yychar = YYEMPTY; /* Cause a token to be read.  */
  1.2064 +  yylsp[0] = yylloc;
  1.2065 +  goto yysetstate;
  1.2066 +
  1.2067 +/*------------------------------------------------------------.
  1.2068 +| yynewstate -- Push a new state, which is found in yystate.  |
  1.2069 +`------------------------------------------------------------*/
  1.2070 + yynewstate:
  1.2071 +  /* In all cases, when you get here, the value and location stacks
  1.2072 +     have just been pushed.  So pushing a state here evens the stacks.  */
  1.2073 +  yyssp++;
  1.2074 +
  1.2075 + yysetstate:
  1.2076 +  *yyssp = yystate;
  1.2077 +
  1.2078 +  if (yyss + yystacksize - 1 <= yyssp)
  1.2079 +    {
  1.2080 +      /* Get the current used size of the three stacks, in elements.  */
  1.2081 +      YYSIZE_T yysize = yyssp - yyss + 1;
  1.2082 +
  1.2083 +#ifdef yyoverflow
  1.2084 +      {
  1.2085 +	/* Give user a chance to reallocate the stack.  Use copies of
  1.2086 +	   these so that the &'s don't force the real ones into
  1.2087 +	   memory.  */
  1.2088 +	YYSTYPE *yyvs1 = yyvs;
  1.2089 +	yytype_int16 *yyss1 = yyss;
  1.2090 +	YYLTYPE *yyls1 = yyls;
  1.2091 +
  1.2092 +	/* Each stack pointer address is followed by the size of the
  1.2093 +	   data in use in that stack, in bytes.  This used to be a
  1.2094 +	   conditional around just the two extra args, but that might
  1.2095 +	   be undefined if yyoverflow is a macro.  */
  1.2096 +	yyoverflow (YY_("memory exhausted"),
  1.2097 +		    &yyss1, yysize * sizeof (*yyssp),
  1.2098 +		    &yyvs1, yysize * sizeof (*yyvsp),
  1.2099 +		    &yyls1, yysize * sizeof (*yylsp),
  1.2100 +		    &yystacksize);
  1.2101 +
  1.2102 +	yyls = yyls1;
  1.2103 +	yyss = yyss1;
  1.2104 +	yyvs = yyvs1;
  1.2105 +      }
  1.2106 +#else /* no yyoverflow */
  1.2107 +# ifndef YYSTACK_RELOCATE
  1.2108 +      goto yyexhaustedlab;
  1.2109 +# else
  1.2110 +      /* Extend the stack our own way.  */
  1.2111 +      if (YYMAXDEPTH <= yystacksize)
  1.2112 +	goto yyexhaustedlab;
  1.2113 +      yystacksize *= 2;
  1.2114 +      if (YYMAXDEPTH < yystacksize)
  1.2115 +	yystacksize = YYMAXDEPTH;
  1.2116 +
  1.2117 +      {
  1.2118 +	yytype_int16 *yyss1 = yyss;
  1.2119 +	union yyalloc *yyptr =
  1.2120 +	  (union yyalloc *) YYSTACK_ALLOC (YYSTACK_BYTES (yystacksize));
  1.2121 +	if (! yyptr)
  1.2122 +	  goto yyexhaustedlab;
  1.2123 +	YYSTACK_RELOCATE (yyss_alloc, yyss);
  1.2124 +	YYSTACK_RELOCATE (yyvs_alloc, yyvs);
  1.2125 +	YYSTACK_RELOCATE (yyls_alloc, yyls);
  1.2126 +#  undef YYSTACK_RELOCATE
  1.2127 +	if (yyss1 != yyssa)
  1.2128 +	  YYSTACK_FREE (yyss1);
  1.2129 +      }
  1.2130 +# endif
  1.2131 +#endif /* no yyoverflow */
  1.2132 +
  1.2133 +      yyssp = yyss + yysize - 1;
  1.2134 +      yyvsp = yyvs + yysize - 1;
  1.2135 +      yylsp = yyls + yysize - 1;
  1.2136 +
  1.2137 +      YYDPRINTF ((stderr, "Stack size increased to %lu\n",
  1.2138 +		  (unsigned long int) yystacksize));
  1.2139 +
  1.2140 +      if (yyss + yystacksize - 1 <= yyssp)
  1.2141 +	YYABORT;
  1.2142 +    }
  1.2143 +
  1.2144 +  YYDPRINTF ((stderr, "Entering state %d\n", yystate));
  1.2145 +
  1.2146 +  if (yystate == YYFINAL)
  1.2147 +    YYACCEPT;
  1.2148 +
  1.2149 +  goto yybackup;
  1.2150 +
  1.2151 +/*-----------.
  1.2152 +| yybackup.  |
  1.2153 +`-----------*/
  1.2154 +yybackup:
  1.2155 +
  1.2156 +  /* Do appropriate processing given the current state.  Read a
  1.2157 +     lookahead token if we need one and don't already have one.  */
  1.2158 +
  1.2159 +  /* First try to decide what to do without reference to lookahead token.  */
  1.2160 +  yyn = yypact[yystate];
  1.2161 +  if (yypact_value_is_default (yyn))
  1.2162 +    goto yydefault;
  1.2163 +
  1.2164 +  /* Not known => get a lookahead token if don't already have one.  */
  1.2165 +
  1.2166 +  /* YYCHAR is either YYEMPTY or YYEOF or a valid lookahead symbol.  */
  1.2167 +  if (yychar == YYEMPTY)
  1.2168 +    {
  1.2169 +      YYDPRINTF ((stderr, "Reading a token: "));
  1.2170 +      yychar = YYLEX;
  1.2171 +    }
  1.2172 +
  1.2173 +  if (yychar <= YYEOF)
  1.2174 +    {
  1.2175 +      yychar = yytoken = YYEOF;
  1.2176 +      YYDPRINTF ((stderr, "Now at end of input.\n"));
  1.2177 +    }
  1.2178 +  else
  1.2179 +    {
  1.2180 +      yytoken = YYTRANSLATE (yychar);
  1.2181 +      YY_SYMBOL_PRINT ("Next token is", yytoken, &yylval, &yylloc);
  1.2182 +    }
  1.2183 +
  1.2184 +  /* If the proper action on seeing token YYTOKEN is to reduce or to
  1.2185 +     detect an error, take that action.  */
  1.2186 +  yyn += yytoken;
  1.2187 +  if (yyn < 0 || YYLAST < yyn || yycheck[yyn] != yytoken)
  1.2188 +    goto yydefault;
  1.2189 +  yyn = yytable[yyn];
  1.2190 +  if (yyn <= 0)
  1.2191 +    {
  1.2192 +      if (yytable_value_is_error (yyn))
  1.2193 +        goto yyerrlab;
  1.2194 +      yyn = -yyn;
  1.2195 +      goto yyreduce;
  1.2196 +    }
  1.2197 +
  1.2198 +  /* Count tokens shifted since error; after three, turn off error
  1.2199 +     status.  */
  1.2200 +  if (yyerrstatus)
  1.2201 +    yyerrstatus--;
  1.2202 +
  1.2203 +  /* Shift the lookahead token.  */
  1.2204 +  YY_SYMBOL_PRINT ("Shifting", yytoken, &yylval, &yylloc);
  1.2205 +
  1.2206 +  /* Discard the shifted token.  */
  1.2207 +  yychar = YYEMPTY;
  1.2208 +
  1.2209 +  yystate = yyn;
  1.2210 +  YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN
  1.2211 +  *++yyvsp = yylval;
  1.2212 +  YY_IGNORE_MAYBE_UNINITIALIZED_END
  1.2213 +  *++yylsp = yylloc;
  1.2214 +  goto yynewstate;
  1.2215 +
  1.2216 +
  1.2217 +/*-----------------------------------------------------------.
  1.2218 +| yydefault -- do the default action for the current state.  |
  1.2219 +`-----------------------------------------------------------*/
  1.2220 +yydefault:
  1.2221 +  yyn = yydefact[yystate];
  1.2222 +  if (yyn == 0)
  1.2223 +    goto yyerrlab;
  1.2224 +  goto yyreduce;
  1.2225 +
  1.2226 +
  1.2227 +/*-----------------------------.
  1.2228 +| yyreduce -- Do a reduction.  |
  1.2229 +`-----------------------------*/
  1.2230 +yyreduce:
  1.2231 +  /* yyn is the number of a rule to reduce with.  */
  1.2232 +  yylen = yyr2[yyn];
  1.2233 +
  1.2234 +  /* If YYLEN is nonzero, implement the default value of the action:
  1.2235 +     `$$ = $1'.
  1.2236 +
  1.2237 +     Otherwise, the following line sets YYVAL to garbage.
  1.2238 +     This behavior is undocumented and Bison
  1.2239 +     users should not rely upon it.  Assigning to YYVAL
  1.2240 +     unconditionally makes the parser a bit smaller, and it avoids a
  1.2241 +     GCC warning that YYVAL may be used uninitialized.  */
  1.2242 +  yyval = yyvsp[1-yylen];
  1.2243 +
  1.2244 +  /* Default location.  */
  1.2245 +  YYLLOC_DEFAULT (yyloc, (yylsp - yylen), yylen);
  1.2246 +  YY_REDUCE_PRINT (yyn);
  1.2247 +  switch (yyn)
  1.2248 +    {
  1.2249 +        case 4:
  1.2250 +
  1.2251 +    {
  1.2252 +        // The symbol table search was done in the lexical phase
  1.2253 +        const TSymbol* symbol = (yyvsp[(1) - (1)].lex).symbol;
  1.2254 +        const TVariable* variable;
  1.2255 +        if (symbol == 0) {
  1.2256 +            context->error((yylsp[(1) - (1)]), "undeclared identifier", (yyvsp[(1) - (1)].lex).string->c_str());
  1.2257 +            context->recover();
  1.2258 +            TType type(EbtFloat, EbpUndefined);
  1.2259 +            TVariable* fakeVariable = new TVariable((yyvsp[(1) - (1)].lex).string, type);
  1.2260 +            context->symbolTable.insert(*fakeVariable);
  1.2261 +            variable = fakeVariable;
  1.2262 +        } else {
  1.2263 +            // This identifier can only be a variable type symbol
  1.2264 +            if (! symbol->isVariable()) {
  1.2265 +                context->error((yylsp[(1) - (1)]), "variable expected", (yyvsp[(1) - (1)].lex).string->c_str());
  1.2266 +                context->recover();
  1.2267 +            }
  1.2268 +            
  1.2269 +            variable = static_cast<const TVariable*>(symbol);
  1.2270 +
  1.2271 +            if (context->symbolTable.findBuiltIn(variable->getName()) &&
  1.2272 +                !variable->getExtension().empty() &&
  1.2273 +                context->extensionErrorCheck((yylsp[(1) - (1)]), variable->getExtension())) {
  1.2274 +                context->recover();
  1.2275 +            }
  1.2276 +        }
  1.2277 +
  1.2278 +        // don't delete $1.string, it's used by error recovery, and the pool
  1.2279 +        // pop will reclaim the memory
  1.2280 +
  1.2281 +        if (variable->getType().getQualifier() == EvqConst ) {
  1.2282 +            ConstantUnion* constArray = variable->getConstPointer();
  1.2283 +            TType t(variable->getType());
  1.2284 +            (yyval.interm.intermTypedNode) = context->intermediate.addConstantUnion(constArray, t, (yylsp[(1) - (1)]));
  1.2285 +        } else
  1.2286 +            (yyval.interm.intermTypedNode) = context->intermediate.addSymbol(variable->getUniqueId(),
  1.2287 +                                                 variable->getName(),
  1.2288 +                                                 variable->getType(),
  1.2289 +                                                 (yylsp[(1) - (1)]));
  1.2290 +    }
  1.2291 +    break;
  1.2292 +
  1.2293 +  case 5:
  1.2294 +
  1.2295 +    {
  1.2296 +        (yyval.interm.intermTypedNode) = (yyvsp[(1) - (1)].interm.intermTypedNode);
  1.2297 +    }
  1.2298 +    break;
  1.2299 +
  1.2300 +  case 6:
  1.2301 +
  1.2302 +    {
  1.2303 +        //
  1.2304 +        // INT_TYPE is only 16-bit plus sign bit for vertex/fragment shaders,
  1.2305 +        // check for overflow for constants
  1.2306 +        //
  1.2307 +        if (abs((yyvsp[(1) - (1)].lex).i) >= (1 << 16)) {
  1.2308 +            context->error((yylsp[(1) - (1)]), " integer constant overflow", "");
  1.2309 +            context->recover();
  1.2310 +        }
  1.2311 +        ConstantUnion *unionArray = new ConstantUnion[1];
  1.2312 +        unionArray->setIConst((yyvsp[(1) - (1)].lex).i);
  1.2313 +        (yyval.interm.intermTypedNode) = context->intermediate.addConstantUnion(unionArray, TType(EbtInt, EbpUndefined, EvqConst), (yylsp[(1) - (1)]));
  1.2314 +    }
  1.2315 +    break;
  1.2316 +
  1.2317 +  case 7:
  1.2318 +
  1.2319 +    {
  1.2320 +        ConstantUnion *unionArray = new ConstantUnion[1];
  1.2321 +        unionArray->setFConst((yyvsp[(1) - (1)].lex).f);
  1.2322 +        (yyval.interm.intermTypedNode) = context->intermediate.addConstantUnion(unionArray, TType(EbtFloat, EbpUndefined, EvqConst), (yylsp[(1) - (1)]));
  1.2323 +    }
  1.2324 +    break;
  1.2325 +
  1.2326 +  case 8:
  1.2327 +
  1.2328 +    {
  1.2329 +        ConstantUnion *unionArray = new ConstantUnion[1];
  1.2330 +        unionArray->setBConst((yyvsp[(1) - (1)].lex).b);
  1.2331 +        (yyval.interm.intermTypedNode) = context->intermediate.addConstantUnion(unionArray, TType(EbtBool, EbpUndefined, EvqConst), (yylsp[(1) - (1)]));
  1.2332 +    }
  1.2333 +    break;
  1.2334 +
  1.2335 +  case 9:
  1.2336 +
  1.2337 +    {
  1.2338 +        (yyval.interm.intermTypedNode) = (yyvsp[(2) - (3)].interm.intermTypedNode);
  1.2339 +    }
  1.2340 +    break;
  1.2341 +
  1.2342 +  case 10:
  1.2343 +
  1.2344 +    {
  1.2345 +        (yyval.interm.intermTypedNode) = (yyvsp[(1) - (1)].interm.intermTypedNode);
  1.2346 +    }
  1.2347 +    break;
  1.2348 +
  1.2349 +  case 11:
  1.2350 +
  1.2351 +    {
  1.2352 +        (yyval.interm.intermTypedNode) = context->addIndexExpression((yyvsp[(1) - (4)].interm.intermTypedNode), (yylsp[(2) - (4)]), (yyvsp[(3) - (4)].interm.intermTypedNode));
  1.2353 +    }
  1.2354 +    break;
  1.2355 +
  1.2356 +  case 12:
  1.2357 +
  1.2358 +    {
  1.2359 +        (yyval.interm.intermTypedNode) = (yyvsp[(1) - (1)].interm.intermTypedNode);
  1.2360 +    }
  1.2361 +    break;
  1.2362 +
  1.2363 +  case 13:
  1.2364 +
  1.2365 +    {
  1.2366 +        if ((yyvsp[(1) - (3)].interm.intermTypedNode)->isArray()) {
  1.2367 +            context->error((yylsp[(3) - (3)]), "cannot apply dot operator to an array", ".");
  1.2368 +            context->recover();
  1.2369 +        }
  1.2370 +
  1.2371 +        if ((yyvsp[(1) - (3)].interm.intermTypedNode)->isVector()) {
  1.2372 +            TVectorFields fields;
  1.2373 +            if (! context->parseVectorFields(*(yyvsp[(3) - (3)].lex).string, (yyvsp[(1) - (3)].interm.intermTypedNode)->getNominalSize(), fields, (yylsp[(3) - (3)]))) {
  1.2374 +                fields.num = 1;
  1.2375 +                fields.offsets[0] = 0;
  1.2376 +                context->recover();
  1.2377 +            }
  1.2378 +
  1.2379 +            if ((yyvsp[(1) - (3)].interm.intermTypedNode)->getType().getQualifier() == EvqConst) { // constant folding for vector fields
  1.2380 +                (yyval.interm.intermTypedNode) = context->addConstVectorNode(fields, (yyvsp[(1) - (3)].interm.intermTypedNode), (yylsp[(3) - (3)]));
  1.2381 +                if ((yyval.interm.intermTypedNode) == 0) {
  1.2382 +                    context->recover();
  1.2383 +                    (yyval.interm.intermTypedNode) = (yyvsp[(1) - (3)].interm.intermTypedNode);
  1.2384 +                }
  1.2385 +                else
  1.2386 +                    (yyval.interm.intermTypedNode)->setType(TType((yyvsp[(1) - (3)].interm.intermTypedNode)->getBasicType(), (yyvsp[(1) - (3)].interm.intermTypedNode)->getPrecision(), EvqConst, (int) (*(yyvsp[(3) - (3)].lex).string).size()));
  1.2387 +            } else {
  1.2388 +                TString vectorString = *(yyvsp[(3) - (3)].lex).string;
  1.2389 +                TIntermTyped* index = context->intermediate.addSwizzle(fields, (yylsp[(3) - (3)]));
  1.2390 +                (yyval.interm.intermTypedNode) = context->intermediate.addIndex(EOpVectorSwizzle, (yyvsp[(1) - (3)].interm.intermTypedNode), index, (yylsp[(2) - (3)]));
  1.2391 +                (yyval.interm.intermTypedNode)->setType(TType((yyvsp[(1) - (3)].interm.intermTypedNode)->getBasicType(), (yyvsp[(1) - (3)].interm.intermTypedNode)->getPrecision(), EvqTemporary, (int) vectorString.size()));
  1.2392 +            }
  1.2393 +        } else if ((yyvsp[(1) - (3)].interm.intermTypedNode)->isMatrix()) {
  1.2394 +            TMatrixFields fields;
  1.2395 +            if (! context->parseMatrixFields(*(yyvsp[(3) - (3)].lex).string, (yyvsp[(1) - (3)].interm.intermTypedNode)->getNominalSize(), fields, (yylsp[(3) - (3)]))) {
  1.2396 +                fields.wholeRow = false;
  1.2397 +                fields.wholeCol = false;
  1.2398 +                fields.row = 0;
  1.2399 +                fields.col = 0;
  1.2400 +                context->recover();
  1.2401 +            }
  1.2402 +
  1.2403 +            if (fields.wholeRow || fields.wholeCol) {
  1.2404 +                context->error((yylsp[(2) - (3)]), " non-scalar fields not implemented yet", ".");
  1.2405 +                context->recover();
  1.2406 +                ConstantUnion *unionArray = new ConstantUnion[1];
  1.2407 +                unionArray->setIConst(0);
  1.2408 +                TIntermTyped* index = context->intermediate.addConstantUnion(unionArray, TType(EbtInt, EbpUndefined, EvqConst), (yylsp[(3) - (3)]));
  1.2409 +                (yyval.interm.intermTypedNode) = context->intermediate.addIndex(EOpIndexDirect, (yyvsp[(1) - (3)].interm.intermTypedNode), index, (yylsp[(2) - (3)]));
  1.2410 +                (yyval.interm.intermTypedNode)->setType(TType((yyvsp[(1) - (3)].interm.intermTypedNode)->getBasicType(), (yyvsp[(1) - (3)].interm.intermTypedNode)->getPrecision(),EvqTemporary, (yyvsp[(1) - (3)].interm.intermTypedNode)->getNominalSize()));
  1.2411 +            } else {
  1.2412 +                ConstantUnion *unionArray = new ConstantUnion[1];
  1.2413 +                unionArray->setIConst(fields.col * (yyvsp[(1) - (3)].interm.intermTypedNode)->getNominalSize() + fields.row);
  1.2414 +                TIntermTyped* index = context->intermediate.addConstantUnion(unionArray, TType(EbtInt, EbpUndefined, EvqConst), (yylsp[(3) - (3)]));
  1.2415 +                (yyval.interm.intermTypedNode) = context->intermediate.addIndex(EOpIndexDirect, (yyvsp[(1) - (3)].interm.intermTypedNode), index, (yylsp[(2) - (3)]));
  1.2416 +                (yyval.interm.intermTypedNode)->setType(TType((yyvsp[(1) - (3)].interm.intermTypedNode)->getBasicType(), (yyvsp[(1) - (3)].interm.intermTypedNode)->getPrecision()));
  1.2417 +            }
  1.2418 +        } else if ((yyvsp[(1) - (3)].interm.intermTypedNode)->getBasicType() == EbtStruct) {
  1.2419 +            bool fieldFound = false;
  1.2420 +            const TFieldList& fields = (yyvsp[(1) - (3)].interm.intermTypedNode)->getType().getStruct()->fields();
  1.2421 +            unsigned int i;
  1.2422 +            for (i = 0; i < fields.size(); ++i) {
  1.2423 +                if (fields[i]->name() == *(yyvsp[(3) - (3)].lex).string) {
  1.2424 +                    fieldFound = true;
  1.2425 +                    break;
  1.2426 +                }
  1.2427 +            }
  1.2428 +            if (fieldFound) {
  1.2429 +                if ((yyvsp[(1) - (3)].interm.intermTypedNode)->getType().getQualifier() == EvqConst) {
  1.2430 +                    (yyval.interm.intermTypedNode) = context->addConstStruct(*(yyvsp[(3) - (3)].lex).string, (yyvsp[(1) - (3)].interm.intermTypedNode), (yylsp[(2) - (3)]));
  1.2431 +                    if ((yyval.interm.intermTypedNode) == 0) {
  1.2432 +                        context->recover();
  1.2433 +                        (yyval.interm.intermTypedNode) = (yyvsp[(1) - (3)].interm.intermTypedNode);
  1.2434 +                    }
  1.2435 +                    else {
  1.2436 +                        (yyval.interm.intermTypedNode)->setType(*fields[i]->type());
  1.2437 +                        // change the qualifier of the return type, not of the structure field
  1.2438 +                        // as the structure definition is shared between various structures.
  1.2439 +                        (yyval.interm.intermTypedNode)->getTypePointer()->setQualifier(EvqConst);
  1.2440 +                    }
  1.2441 +                } else {
  1.2442 +                    ConstantUnion *unionArray = new ConstantUnion[1];
  1.2443 +                    unionArray->setIConst(i);
  1.2444 +                    TIntermTyped* index = context->intermediate.addConstantUnion(unionArray, *fields[i]->type(), (yylsp[(3) - (3)]));
  1.2445 +                    (yyval.interm.intermTypedNode) = context->intermediate.addIndex(EOpIndexDirectStruct, (yyvsp[(1) - (3)].interm.intermTypedNode), index, (yylsp[(2) - (3)]));
  1.2446 +                    (yyval.interm.intermTypedNode)->setType(*fields[i]->type());
  1.2447 +                }
  1.2448 +            } else {
  1.2449 +                context->error((yylsp[(2) - (3)]), " no such field in structure", (yyvsp[(3) - (3)].lex).string->c_str());
  1.2450 +                context->recover();
  1.2451 +                (yyval.interm.intermTypedNode) = (yyvsp[(1) - (3)].interm.intermTypedNode);
  1.2452 +            }
  1.2453 +        } else {
  1.2454 +            context->error((yylsp[(2) - (3)]), " field selection requires structure, vector, or matrix on left hand side", (yyvsp[(3) - (3)].lex).string->c_str());
  1.2455 +            context->recover();
  1.2456 +            (yyval.interm.intermTypedNode) = (yyvsp[(1) - (3)].interm.intermTypedNode);
  1.2457 +        }
  1.2458 +        // don't delete $3.string, it's from the pool
  1.2459 +    }
  1.2460 +    break;
  1.2461 +
  1.2462 +  case 14:
  1.2463 +
  1.2464 +    {
  1.2465 +        if (context->lValueErrorCheck((yylsp[(2) - (2)]), "++", (yyvsp[(1) - (2)].interm.intermTypedNode)))
  1.2466 +            context->recover();
  1.2467 +        (yyval.interm.intermTypedNode) = context->intermediate.addUnaryMath(EOpPostIncrement, (yyvsp[(1) - (2)].interm.intermTypedNode), (yylsp[(2) - (2)]), context->symbolTable);
  1.2468 +        if ((yyval.interm.intermTypedNode) == 0) {
  1.2469 +            context->unaryOpError((yylsp[(2) - (2)]), "++", (yyvsp[(1) - (2)].interm.intermTypedNode)->getCompleteString());
  1.2470 +            context->recover();
  1.2471 +            (yyval.interm.intermTypedNode) = (yyvsp[(1) - (2)].interm.intermTypedNode);
  1.2472 +        }
  1.2473 +    }
  1.2474 +    break;
  1.2475 +
  1.2476 +  case 15:
  1.2477 +
  1.2478 +    {
  1.2479 +        if (context->lValueErrorCheck((yylsp[(2) - (2)]), "--", (yyvsp[(1) - (2)].interm.intermTypedNode)))
  1.2480 +            context->recover();
  1.2481 +        (yyval.interm.intermTypedNode) = context->intermediate.addUnaryMath(EOpPostDecrement, (yyvsp[(1) - (2)].interm.intermTypedNode), (yylsp[(2) - (2)]), context->symbolTable);
  1.2482 +        if ((yyval.interm.intermTypedNode) == 0) {
  1.2483 +            context->unaryOpError((yylsp[(2) - (2)]), "--", (yyvsp[(1) - (2)].interm.intermTypedNode)->getCompleteString());
  1.2484 +            context->recover();
  1.2485 +            (yyval.interm.intermTypedNode) = (yyvsp[(1) - (2)].interm.intermTypedNode);
  1.2486 +        }
  1.2487 +    }
  1.2488 +    break;
  1.2489 +
  1.2490 +  case 16:
  1.2491 +
  1.2492 +    {
  1.2493 +        if (context->integerErrorCheck((yyvsp[(1) - (1)].interm.intermTypedNode), "[]"))
  1.2494 +            context->recover();
  1.2495 +        (yyval.interm.intermTypedNode) = (yyvsp[(1) - (1)].interm.intermTypedNode);
  1.2496 +    }
  1.2497 +    break;
  1.2498 +
  1.2499 +  case 17:
  1.2500 +
  1.2501 +    {
  1.2502 +        TFunction* fnCall = (yyvsp[(1) - (1)].interm).function;
  1.2503 +        TOperator op = fnCall->getBuiltInOp();
  1.2504 +
  1.2505 +        if (op != EOpNull)
  1.2506 +        {
  1.2507 +            //
  1.2508 +            // Then this should be a constructor.
  1.2509 +            // Don't go through the symbol table for constructors.
  1.2510 +            // Their parameters will be verified algorithmically.
  1.2511 +            //
  1.2512 +            TType type(EbtVoid, EbpUndefined);  // use this to get the type back
  1.2513 +            if (context->constructorErrorCheck((yylsp[(1) - (1)]), (yyvsp[(1) - (1)].interm).intermNode, *fnCall, op, &type)) {
  1.2514 +                (yyval.interm.intermTypedNode) = 0;
  1.2515 +            } else {
  1.2516 +                //
  1.2517 +                // It's a constructor, of type 'type'.
  1.2518 +                //
  1.2519 +                (yyval.interm.intermTypedNode) = context->addConstructor((yyvsp[(1) - (1)].interm).intermNode, &type, op, fnCall, (yylsp[(1) - (1)]));
  1.2520 +            }
  1.2521 +
  1.2522 +            if ((yyval.interm.intermTypedNode) == 0) {
  1.2523 +                context->recover();
  1.2524 +                (yyval.interm.intermTypedNode) = context->intermediate.setAggregateOperator(0, op, (yylsp[(1) - (1)]));
  1.2525 +            }
  1.2526 +            (yyval.interm.intermTypedNode)->setType(type);
  1.2527 +        } else {
  1.2528 +            //
  1.2529 +            // Not a constructor.  Find it in the symbol table.
  1.2530 +            //
  1.2531 +            const TFunction* fnCandidate;
  1.2532 +            bool builtIn;
  1.2533 +            fnCandidate = context->findFunction((yylsp[(1) - (1)]), fnCall, &builtIn);
  1.2534 +            if (fnCandidate) {
  1.2535 +                //
  1.2536 +                // A declared function.
  1.2537 +                //
  1.2538 +                if (builtIn && !fnCandidate->getExtension().empty() &&
  1.2539 +                    context->extensionErrorCheck((yylsp[(1) - (1)]), fnCandidate->getExtension())) {
  1.2540 +                    context->recover();
  1.2541 +                }
  1.2542 +                op = fnCandidate->getBuiltInOp();
  1.2543 +                if (builtIn && op != EOpNull) {
  1.2544 +                    //
  1.2545 +                    // A function call mapped to a built-in operation.
  1.2546 +                    //
  1.2547 +                    if (fnCandidate->getParamCount() == 1) {
  1.2548 +                        //
  1.2549 +                        // Treat it like a built-in unary operator.
  1.2550 +                        //
  1.2551 +                        (yyval.interm.intermTypedNode) = context->intermediate.addUnaryMath(op, (yyvsp[(1) - (1)].interm).intermNode, (yylsp[(1) - (1)]), context->symbolTable);
  1.2552 +                        if ((yyval.interm.intermTypedNode) == 0)  {
  1.2553 +                            std::stringstream extraInfoStream;
  1.2554 +                            extraInfoStream << "built in unary operator function.  Type: " << static_cast<TIntermTyped*>((yyvsp[(1) - (1)].interm).intermNode)->getCompleteString();
  1.2555 +                            std::string extraInfo = extraInfoStream.str();
  1.2556 +                            context->error((yyvsp[(1) - (1)].interm).intermNode->getLine(), " wrong operand type", "Internal Error", extraInfo.c_str());
  1.2557 +                            YYERROR;
  1.2558 +                        }
  1.2559 +                    } else {
  1.2560 +                        (yyval.interm.intermTypedNode) = context->intermediate.setAggregateOperator((yyvsp[(1) - (1)].interm).intermAggregate, op, (yylsp[(1) - (1)]));
  1.2561 +                    }
  1.2562 +                } else {
  1.2563 +                    // This is a real function call
  1.2564 +
  1.2565 +                    (yyval.interm.intermTypedNode) = context->intermediate.setAggregateOperator((yyvsp[(1) - (1)].interm).intermAggregate, EOpFunctionCall, (yylsp[(1) - (1)]));
  1.2566 +                    (yyval.interm.intermTypedNode)->setType(fnCandidate->getReturnType());
  1.2567 +
  1.2568 +                    // this is how we know whether the given function is a builtIn function or a user defined function
  1.2569 +                    // if builtIn == false, it's a userDefined -> could be an overloaded builtIn function also
  1.2570 +                    // if builtIn == true, it's definitely a builtIn function with EOpNull
  1.2571 +                    if (!builtIn)
  1.2572 +                        (yyval.interm.intermTypedNode)->getAsAggregate()->setUserDefined();
  1.2573 +                    (yyval.interm.intermTypedNode)->getAsAggregate()->setName(fnCandidate->getMangledName());
  1.2574 +
  1.2575 +                    TQualifier qual;
  1.2576 +                    for (size_t i = 0; i < fnCandidate->getParamCount(); ++i) {
  1.2577 +                        qual = fnCandidate->getParam(i).type->getQualifier();
  1.2578 +                        if (qual == EvqOut || qual == EvqInOut) {
  1.2579 +                            if (context->lValueErrorCheck((yyval.interm.intermTypedNode)->getLine(), "assign", (yyval.interm.intermTypedNode)->getAsAggregate()->getSequence()[i]->getAsTyped())) {
  1.2580 +                                context->error((yyvsp[(1) - (1)].interm).intermNode->getLine(), "Constant value cannot be passed for 'out' or 'inout' parameters.", "Error");
  1.2581 +                                context->recover();
  1.2582 +                            }
  1.2583 +                        }
  1.2584 +                    }
  1.2585 +                }
  1.2586 +                (yyval.interm.intermTypedNode)->setType(fnCandidate->getReturnType());
  1.2587 +            } else {
  1.2588 +                // error message was put out by PaFindFunction()
  1.2589 +                // Put on a dummy node for error recovery
  1.2590 +                ConstantUnion *unionArray = new ConstantUnion[1];
  1.2591 +                unionArray->setFConst(0.0f);
  1.2592 +                (yyval.interm.intermTypedNode) = context->intermediate.addConstantUnion(unionArray, TType(EbtFloat, EbpUndefined, EvqConst), (yylsp[(1) - (1)]));
  1.2593 +                context->recover();
  1.2594 +            }
  1.2595 +        }
  1.2596 +        delete fnCall;
  1.2597 +    }
  1.2598 +    break;
  1.2599 +
  1.2600 +  case 18:
  1.2601 +
  1.2602 +    {
  1.2603 +        (yyval.interm) = (yyvsp[(1) - (1)].interm);
  1.2604 +    }
  1.2605 +    break;
  1.2606 +
  1.2607 +  case 19:
  1.2608 +
  1.2609 +    {
  1.2610 +        context->error((yylsp[(3) - (3)]), "methods are not supported", "");
  1.2611 +        context->recover();
  1.2612 +        (yyval.interm) = (yyvsp[(3) - (3)].interm);
  1.2613 +    }
  1.2614 +    break;
  1.2615 +
  1.2616 +  case 20:
  1.2617 +
  1.2618 +    {
  1.2619 +        (yyval.interm) = (yyvsp[(1) - (2)].interm);
  1.2620 +    }
  1.2621 +    break;
  1.2622 +
  1.2623 +  case 21:
  1.2624 +
  1.2625 +    {
  1.2626 +        (yyval.interm) = (yyvsp[(1) - (2)].interm);
  1.2627 +    }
  1.2628 +    break;
  1.2629 +
  1.2630 +  case 22:
  1.2631 +
  1.2632 +    {
  1.2633 +        (yyval.interm).function = (yyvsp[(1) - (2)].interm.function);
  1.2634 +        (yyval.interm).intermNode = 0;
  1.2635 +    }
  1.2636 +    break;
  1.2637 +
  1.2638 +  case 23:
  1.2639 +
  1.2640 +    {
  1.2641 +        (yyval.interm).function = (yyvsp[(1) - (1)].interm.function);
  1.2642 +        (yyval.interm).intermNode = 0;
  1.2643 +    }
  1.2644 +    break;
  1.2645 +
  1.2646 +  case 24:
  1.2647 +
  1.2648 +    {
  1.2649 +        TParameter param = { 0, new TType((yyvsp[(2) - (2)].interm.intermTypedNode)->getType()) };
  1.2650 +        (yyvsp[(1) - (2)].interm.function)->addParameter(param);
  1.2651 +        (yyval.interm).function = (yyvsp[(1) - (2)].interm.function);
  1.2652 +        (yyval.interm).intermNode = (yyvsp[(2) - (2)].interm.intermTypedNode);
  1.2653 +    }
  1.2654 +    break;
  1.2655 +
  1.2656 +  case 25:
  1.2657 +
  1.2658 +    {
  1.2659 +        TParameter param = { 0, new TType((yyvsp[(3) - (3)].interm.intermTypedNode)->getType()) };
  1.2660 +        (yyvsp[(1) - (3)].interm).function->addParameter(param);
  1.2661 +        (yyval.interm).function = (yyvsp[(1) - (3)].interm).function;
  1.2662 +        (yyval.interm).intermNode = context->intermediate.growAggregate((yyvsp[(1) - (3)].interm).intermNode, (yyvsp[(3) - (3)].interm.intermTypedNode), (yylsp[(2) - (3)]));
  1.2663 +    }
  1.2664 +    break;
  1.2665 +
  1.2666 +  case 26:
  1.2667 +
  1.2668 +    {
  1.2669 +        (yyval.interm.function) = (yyvsp[(1) - (2)].interm.function);
  1.2670 +    }
  1.2671 +    break;
  1.2672 +
  1.2673 +  case 27:
  1.2674 +
  1.2675 +    {
  1.2676 +        //
  1.2677 +        // Constructor
  1.2678 +        //
  1.2679 +        TOperator op = EOpNull;
  1.2680 +        if ((yyvsp[(1) - (1)].interm.type).userDef) {
  1.2681 +            op = EOpConstructStruct;
  1.2682 +        } else {
  1.2683 +            switch ((yyvsp[(1) - (1)].interm.type).type) {
  1.2684 +            case EbtFloat:
  1.2685 +                if ((yyvsp[(1) - (1)].interm.type).matrix) {
  1.2686 +                    switch((yyvsp[(1) - (1)].interm.type).size) {
  1.2687 +                    case 2: op = EOpConstructMat2;  break;
  1.2688 +                    case 3: op = EOpConstructMat3;  break;
  1.2689 +                    case 4: op = EOpConstructMat4;  break;
  1.2690 +                    }
  1.2691 +                } else {
  1.2692 +                    switch((yyvsp[(1) - (1)].interm.type).size) {
  1.2693 +                    case 1: op = EOpConstructFloat; break;
  1.2694 +                    case 2: op = EOpConstructVec2;  break;
  1.2695 +                    case 3: op = EOpConstructVec3;  break;
  1.2696 +                    case 4: op = EOpConstructVec4;  break;
  1.2697 +                    }
  1.2698 +                }
  1.2699 +                break;
  1.2700 +            case EbtInt:
  1.2701 +                switch((yyvsp[(1) - (1)].interm.type).size) {
  1.2702 +                case 1: op = EOpConstructInt;   break;
  1.2703 +                case 2: op = EOpConstructIVec2; break;
  1.2704 +                case 3: op = EOpConstructIVec3; break;
  1.2705 +                case 4: op = EOpConstructIVec4; break;
  1.2706 +                }
  1.2707 +                break;
  1.2708 +            case EbtBool:
  1.2709 +                switch((yyvsp[(1) - (1)].interm.type).size) {
  1.2710 +                case 1: op = EOpConstructBool;  break;
  1.2711 +                case 2: op = EOpConstructBVec2; break;
  1.2712 +                case 3: op = EOpConstructBVec3; break;
  1.2713 +                case 4: op = EOpConstructBVec4; break;
  1.2714 +                }
  1.2715 +                break;
  1.2716 +            default: break;
  1.2717 +            }
  1.2718 +            if (op == EOpNull) {
  1.2719 +                context->error((yylsp[(1) - (1)]), "cannot construct this type", getBasicString((yyvsp[(1) - (1)].interm.type).type));
  1.2720 +                context->recover();
  1.2721 +                (yyvsp[(1) - (1)].interm.type).type = EbtFloat;
  1.2722 +                op = EOpConstructFloat;
  1.2723 +            }
  1.2724 +        }
  1.2725 +        TString tempString;
  1.2726 +        TType type((yyvsp[(1) - (1)].interm.type));
  1.2727 +        TFunction *function = new TFunction(&tempString, type, op);
  1.2728 +        (yyval.interm.function) = function;
  1.2729 +    }
  1.2730 +    break;
  1.2731 +
  1.2732 +  case 28:
  1.2733 +
  1.2734 +    {
  1.2735 +        if (context->reservedErrorCheck((yylsp[(1) - (1)]), *(yyvsp[(1) - (1)].lex).string))
  1.2736 +            context->recover();
  1.2737 +        TType type(EbtVoid, EbpUndefined);
  1.2738 +        TFunction *function = new TFunction((yyvsp[(1) - (1)].lex).string, type);
  1.2739 +        (yyval.interm.function) = function;
  1.2740 +    }
  1.2741 +    break;
  1.2742 +
  1.2743 +  case 29:
  1.2744 +
  1.2745 +    {
  1.2746 +        (yyval.interm.intermTypedNode) = (yyvsp[(1) - (1)].interm.intermTypedNode);
  1.2747 +    }
  1.2748 +    break;
  1.2749 +
  1.2750 +  case 30:
  1.2751 +
  1.2752 +    {
  1.2753 +        if (context->lValueErrorCheck((yylsp[(1) - (2)]), "++", (yyvsp[(2) - (2)].interm.intermTypedNode)))
  1.2754 +            context->recover();
  1.2755 +        (yyval.interm.intermTypedNode) = context->intermediate.addUnaryMath(EOpPreIncrement, (yyvsp[(2) - (2)].interm.intermTypedNode), (yylsp[(1) - (2)]), context->symbolTable);
  1.2756 +        if ((yyval.interm.intermTypedNode) == 0) {
  1.2757 +            context->unaryOpError((yylsp[(1) - (2)]), "++", (yyvsp[(2) - (2)].interm.intermTypedNode)->getCompleteString());
  1.2758 +            context->recover();
  1.2759 +            (yyval.interm.intermTypedNode) = (yyvsp[(2) - (2)].interm.intermTypedNode);
  1.2760 +        }
  1.2761 +    }
  1.2762 +    break;
  1.2763 +
  1.2764 +  case 31:
  1.2765 +
  1.2766 +    {
  1.2767 +        if (context->lValueErrorCheck((yylsp[(1) - (2)]), "--", (yyvsp[(2) - (2)].interm.intermTypedNode)))
  1.2768 +            context->recover();
  1.2769 +        (yyval.interm.intermTypedNode) = context->intermediate.addUnaryMath(EOpPreDecrement, (yyvsp[(2) - (2)].interm.intermTypedNode), (yylsp[(1) - (2)]), context->symbolTable);
  1.2770 +        if ((yyval.interm.intermTypedNode) == 0) {
  1.2771 +            context->unaryOpError((yylsp[(1) - (2)]), "--", (yyvsp[(2) - (2)].interm.intermTypedNode)->getCompleteString());
  1.2772 +            context->recover();
  1.2773 +            (yyval.interm.intermTypedNode) = (yyvsp[(2) - (2)].interm.intermTypedNode);
  1.2774 +        }
  1.2775 +    }
  1.2776 +    break;
  1.2777 +
  1.2778 +  case 32:
  1.2779 +
  1.2780 +    {
  1.2781 +        if ((yyvsp[(1) - (2)].interm).op != EOpNull) {
  1.2782 +            (yyval.interm.intermTypedNode) = context->intermediate.addUnaryMath((yyvsp[(1) - (2)].interm).op, (yyvsp[(2) - (2)].interm.intermTypedNode), (yylsp[(1) - (2)]), context->symbolTable);
  1.2783 +            if ((yyval.interm.intermTypedNode) == 0) {
  1.2784 +                const char* errorOp = "";
  1.2785 +                switch((yyvsp[(1) - (2)].interm).op) {
  1.2786 +                case EOpNegative:   errorOp = "-"; break;
  1.2787 +                case EOpLogicalNot: errorOp = "!"; break;
  1.2788 +                default: break;
  1.2789 +                }
  1.2790 +                context->unaryOpError((yylsp[(1) - (2)]), errorOp, (yyvsp[(2) - (2)].interm.intermTypedNode)->getCompleteString());
  1.2791 +                context->recover();
  1.2792 +                (yyval.interm.intermTypedNode) = (yyvsp[(2) - (2)].interm.intermTypedNode);
  1.2793 +            }
  1.2794 +        } else
  1.2795 +            (yyval.interm.intermTypedNode) = (yyvsp[(2) - (2)].interm.intermTypedNode);
  1.2796 +    }
  1.2797 +    break;
  1.2798 +
  1.2799 +  case 33:
  1.2800 +
  1.2801 +    { (yyval.interm).op = EOpNull; }
  1.2802 +    break;
  1.2803 +
  1.2804 +  case 34:
  1.2805 +
  1.2806 +    { (yyval.interm).op = EOpNegative; }
  1.2807 +    break;
  1.2808 +
  1.2809 +  case 35:
  1.2810 +
  1.2811 +    { (yyval.interm).op = EOpLogicalNot; }
  1.2812 +    break;
  1.2813 +
  1.2814 +  case 36:
  1.2815 +
  1.2816 +    { (yyval.interm.intermTypedNode) = (yyvsp[(1) - (1)].interm.intermTypedNode); }
  1.2817 +    break;
  1.2818 +
  1.2819 +  case 37:
  1.2820 +
  1.2821 +    {
  1.2822 +        (yyval.interm.intermTypedNode) = context->intermediate.addBinaryMath(EOpMul, (yyvsp[(1) - (3)].interm.intermTypedNode), (yyvsp[(3) - (3)].interm.intermTypedNode), (yylsp[(2) - (3)]), context->symbolTable);
  1.2823 +        if ((yyval.interm.intermTypedNode) == 0) {
  1.2824 +            context->binaryOpError((yylsp[(2) - (3)]), "*", (yyvsp[(1) - (3)].interm.intermTypedNode)->getCompleteString(), (yyvsp[(3) - (3)].interm.intermTypedNode)->getCompleteString());
  1.2825 +            context->recover();
  1.2826 +            (yyval.interm.intermTypedNode) = (yyvsp[(1) - (3)].interm.intermTypedNode);
  1.2827 +        }
  1.2828 +    }
  1.2829 +    break;
  1.2830 +
  1.2831 +  case 38:
  1.2832 +
  1.2833 +    {
  1.2834 +        (yyval.interm.intermTypedNode) = context->intermediate.addBinaryMath(EOpDiv, (yyvsp[(1) - (3)].interm.intermTypedNode), (yyvsp[(3) - (3)].interm.intermTypedNode), (yylsp[(2) - (3)]), context->symbolTable);
  1.2835 +        if ((yyval.interm.intermTypedNode) == 0) {
  1.2836 +            context->binaryOpError((yylsp[(2) - (3)]), "/", (yyvsp[(1) - (3)].interm.intermTypedNode)->getCompleteString(), (yyvsp[(3) - (3)].interm.intermTypedNode)->getCompleteString());
  1.2837 +            context->recover();
  1.2838 +            (yyval.interm.intermTypedNode) = (yyvsp[(1) - (3)].interm.intermTypedNode);
  1.2839 +        }
  1.2840 +    }
  1.2841 +    break;
  1.2842 +
  1.2843 +  case 39:
  1.2844 +
  1.2845 +    { (yyval.interm.intermTypedNode) = (yyvsp[(1) - (1)].interm.intermTypedNode); }
  1.2846 +    break;
  1.2847 +
  1.2848 +  case 40:
  1.2849 +
  1.2850 +    {
  1.2851 +        (yyval.interm.intermTypedNode) = context->intermediate.addBinaryMath(EOpAdd, (yyvsp[(1) - (3)].interm.intermTypedNode), (yyvsp[(3) - (3)].interm.intermTypedNode), (yylsp[(2) - (3)]), context->symbolTable);
  1.2852 +        if ((yyval.interm.intermTypedNode) == 0) {
  1.2853 +            context->binaryOpError((yylsp[(2) - (3)]), "+", (yyvsp[(1) - (3)].interm.intermTypedNode)->getCompleteString(), (yyvsp[(3) - (3)].interm.intermTypedNode)->getCompleteString());
  1.2854 +            context->recover();
  1.2855 +            (yyval.interm.intermTypedNode) = (yyvsp[(1) - (3)].interm.intermTypedNode);
  1.2856 +        }
  1.2857 +    }
  1.2858 +    break;
  1.2859 +
  1.2860 +  case 41:
  1.2861 +
  1.2862 +    {
  1.2863 +        (yyval.interm.intermTypedNode) = context->intermediate.addBinaryMath(EOpSub, (yyvsp[(1) - (3)].interm.intermTypedNode), (yyvsp[(3) - (3)].interm.intermTypedNode), (yylsp[(2) - (3)]), context->symbolTable);
  1.2864 +        if ((yyval.interm.intermTypedNode) == 0) {
  1.2865 +            context->binaryOpError((yylsp[(2) - (3)]), "-", (yyvsp[(1) - (3)].interm.intermTypedNode)->getCompleteString(), (yyvsp[(3) - (3)].interm.intermTypedNode)->getCompleteString());
  1.2866 +            context->recover();
  1.2867 +            (yyval.interm.intermTypedNode) = (yyvsp[(1) - (3)].interm.intermTypedNode);
  1.2868 +        }
  1.2869 +    }
  1.2870 +    break;
  1.2871 +
  1.2872 +  case 42:
  1.2873 +
  1.2874 +    { (yyval.interm.intermTypedNode) = (yyvsp[(1) - (1)].interm.intermTypedNode); }
  1.2875 +    break;
  1.2876 +
  1.2877 +  case 43:
  1.2878 +
  1.2879 +    { (yyval.interm.intermTypedNode) = (yyvsp[(1) - (1)].interm.intermTypedNode); }
  1.2880 +    break;
  1.2881 +
  1.2882 +  case 44:
  1.2883 +
  1.2884 +    {
  1.2885 +        (yyval.interm.intermTypedNode) = context->intermediate.addBinaryMath(EOpLessThan, (yyvsp[(1) - (3)].interm.intermTypedNode), (yyvsp[(3) - (3)].interm.intermTypedNode), (yylsp[(2) - (3)]), context->symbolTable);
  1.2886 +        if ((yyval.interm.intermTypedNode) == 0) {
  1.2887 +            context->binaryOpError((yylsp[(2) - (3)]), "<", (yyvsp[(1) - (3)].interm.intermTypedNode)->getCompleteString(), (yyvsp[(3) - (3)].interm.intermTypedNode)->getCompleteString());
  1.2888 +            context->recover();
  1.2889 +            ConstantUnion *unionArray = new ConstantUnion[1];
  1.2890 +            unionArray->setBConst(false);
  1.2891 +            (yyval.interm.intermTypedNode) = context->intermediate.addConstantUnion(unionArray, TType(EbtBool, EbpUndefined, EvqConst), (yylsp[(2) - (3)]));
  1.2892 +        }
  1.2893 +    }
  1.2894 +    break;
  1.2895 +
  1.2896 +  case 45:
  1.2897 +
  1.2898 +    {
  1.2899 +        (yyval.interm.intermTypedNode) = context->intermediate.addBinaryMath(EOpGreaterThan, (yyvsp[(1) - (3)].interm.intermTypedNode), (yyvsp[(3) - (3)].interm.intermTypedNode), (yylsp[(2) - (3)]), context->symbolTable);
  1.2900 +        if ((yyval.interm.intermTypedNode) == 0) {
  1.2901 +            context->binaryOpError((yylsp[(2) - (3)]), ">", (yyvsp[(1) - (3)].interm.intermTypedNode)->getCompleteString(), (yyvsp[(3) - (3)].interm.intermTypedNode)->getCompleteString());
  1.2902 +            context->recover();
  1.2903 +            ConstantUnion *unionArray = new ConstantUnion[1];
  1.2904 +            unionArray->setBConst(false);
  1.2905 +            (yyval.interm.intermTypedNode) = context->intermediate.addConstantUnion(unionArray, TType(EbtBool, EbpUndefined, EvqConst), (yylsp[(2) - (3)]));
  1.2906 +        }
  1.2907 +    }
  1.2908 +    break;
  1.2909 +
  1.2910 +  case 46:
  1.2911 +
  1.2912 +    {
  1.2913 +        (yyval.interm.intermTypedNode) = context->intermediate.addBinaryMath(EOpLessThanEqual, (yyvsp[(1) - (3)].interm.intermTypedNode), (yyvsp[(3) - (3)].interm.intermTypedNode), (yylsp[(2) - (3)]), context->symbolTable);
  1.2914 +        if ((yyval.interm.intermTypedNode) == 0) {
  1.2915 +            context->binaryOpError((yylsp[(2) - (3)]), "<=", (yyvsp[(1) - (3)].interm.intermTypedNode)->getCompleteString(), (yyvsp[(3) - (3)].interm.intermTypedNode)->getCompleteString());
  1.2916 +            context->recover();
  1.2917 +            ConstantUnion *unionArray = new ConstantUnion[1];
  1.2918 +            unionArray->setBConst(false);
  1.2919 +            (yyval.interm.intermTypedNode) = context->intermediate.addConstantUnion(unionArray, TType(EbtBool, EbpUndefined, EvqConst), (yylsp[(2) - (3)]));
  1.2920 +        }
  1.2921 +    }
  1.2922 +    break;
  1.2923 +
  1.2924 +  case 47:
  1.2925 +
  1.2926 +    {
  1.2927 +        (yyval.interm.intermTypedNode) = context->intermediate.addBinaryMath(EOpGreaterThanEqual, (yyvsp[(1) - (3)].interm.intermTypedNode), (yyvsp[(3) - (3)].interm.intermTypedNode), (yylsp[(2) - (3)]), context->symbolTable);
  1.2928 +        if ((yyval.interm.intermTypedNode) == 0) {
  1.2929 +            context->binaryOpError((yylsp[(2) - (3)]), ">=", (yyvsp[(1) - (3)].interm.intermTypedNode)->getCompleteString(), (yyvsp[(3) - (3)].interm.intermTypedNode)->getCompleteString());
  1.2930 +            context->recover();
  1.2931 +            ConstantUnion *unionArray = new ConstantUnion[1];
  1.2932 +            unionArray->setBConst(false);
  1.2933 +            (yyval.interm.intermTypedNode) = context->intermediate.addConstantUnion(unionArray, TType(EbtBool, EbpUndefined, EvqConst), (yylsp[(2) - (3)]));
  1.2934 +        }
  1.2935 +    }
  1.2936 +    break;
  1.2937 +
  1.2938 +  case 48:
  1.2939 +
  1.2940 +    { (yyval.interm.intermTypedNode) = (yyvsp[(1) - (1)].interm.intermTypedNode); }
  1.2941 +    break;
  1.2942 +
  1.2943 +  case 49:
  1.2944 +
  1.2945 +    {
  1.2946 +        (yyval.interm.intermTypedNode) = context->intermediate.addBinaryMath(EOpEqual, (yyvsp[(1) - (3)].interm.intermTypedNode), (yyvsp[(3) - (3)].interm.intermTypedNode), (yylsp[(2) - (3)]), context->symbolTable);
  1.2947 +        if ((yyval.interm.intermTypedNode) == 0) {
  1.2948 +            context->binaryOpError((yylsp[(2) - (3)]), "==", (yyvsp[(1) - (3)].interm.intermTypedNode)->getCompleteString(), (yyvsp[(3) - (3)].interm.intermTypedNode)->getCompleteString());
  1.2949 +            context->recover();
  1.2950 +            ConstantUnion *unionArray = new ConstantUnion[1];
  1.2951 +            unionArray->setBConst(false);
  1.2952 +            (yyval.interm.intermTypedNode) = context->intermediate.addConstantUnion(unionArray, TType(EbtBool, EbpUndefined, EvqConst), (yylsp[(2) - (3)]));
  1.2953 +        }
  1.2954 +    }
  1.2955 +    break;
  1.2956 +
  1.2957 +  case 50:
  1.2958 +
  1.2959 +    {
  1.2960 +        (yyval.interm.intermTypedNode) = context->intermediate.addBinaryMath(EOpNotEqual, (yyvsp[(1) - (3)].interm.intermTypedNode), (yyvsp[(3) - (3)].interm.intermTypedNode), (yylsp[(2) - (3)]), context->symbolTable);
  1.2961 +        if ((yyval.interm.intermTypedNode) == 0) {
  1.2962 +            context->binaryOpError((yylsp[(2) - (3)]), "!=", (yyvsp[(1) - (3)].interm.intermTypedNode)->getCompleteString(), (yyvsp[(3) - (3)].interm.intermTypedNode)->getCompleteString());
  1.2963 +            context->recover();
  1.2964 +            ConstantUnion *unionArray = new ConstantUnion[1];
  1.2965 +            unionArray->setBConst(false);
  1.2966 +            (yyval.interm.intermTypedNode) = context->intermediate.addConstantUnion(unionArray, TType(EbtBool, EbpUndefined, EvqConst), (yylsp[(2) - (3)]));
  1.2967 +        }
  1.2968 +    }
  1.2969 +    break;
  1.2970 +
  1.2971 +  case 51:
  1.2972 +
  1.2973 +    { (yyval.interm.intermTypedNode) = (yyvsp[(1) - (1)].interm.intermTypedNode); }
  1.2974 +    break;
  1.2975 +
  1.2976 +  case 52:
  1.2977 +
  1.2978 +    { (yyval.interm.intermTypedNode) = (yyvsp[(1) - (1)].interm.intermTypedNode); }
  1.2979 +    break;
  1.2980 +
  1.2981 +  case 53:
  1.2982 +
  1.2983 +    { (yyval.interm.intermTypedNode) = (yyvsp[(1) - (1)].interm.intermTypedNode); }
  1.2984 +    break;
  1.2985 +
  1.2986 +  case 54:
  1.2987 +
  1.2988 +    { (yyval.interm.intermTypedNode) = (yyvsp[(1) - (1)].interm.intermTypedNode); }
  1.2989 +    break;
  1.2990 +
  1.2991 +  case 55:
  1.2992 +
  1.2993 +    {
  1.2994 +        (yyval.interm.intermTypedNode) = context->intermediate.addBinaryMath(EOpLogicalAnd, (yyvsp[(1) - (3)].interm.intermTypedNode), (yyvsp[(3) - (3)].interm.intermTypedNode), (yylsp[(2) - (3)]), context->symbolTable);
  1.2995 +        if ((yyval.interm.intermTypedNode) == 0) {
  1.2996 +            context->binaryOpError((yylsp[(2) - (3)]), "&&", (yyvsp[(1) - (3)].interm.intermTypedNode)->getCompleteString(), (yyvsp[(3) - (3)].interm.intermTypedNode)->getCompleteString());
  1.2997 +            context->recover();
  1.2998 +            ConstantUnion *unionArray = new ConstantUnion[1];
  1.2999 +            unionArray->setBConst(false);
  1.3000 +            (yyval.interm.intermTypedNode) = context->intermediate.addConstantUnion(unionArray, TType(EbtBool, EbpUndefined, EvqConst), (yylsp[(2) - (3)]));
  1.3001 +        }
  1.3002 +    }
  1.3003 +    break;
  1.3004 +
  1.3005 +  case 56:
  1.3006 +
  1.3007 +    { (yyval.interm.intermTypedNode) = (yyvsp[(1) - (1)].interm.intermTypedNode); }
  1.3008 +    break;
  1.3009 +
  1.3010 +  case 57:
  1.3011 +
  1.3012 +    {
  1.3013 +        (yyval.interm.intermTypedNode) = context->intermediate.addBinaryMath(EOpLogicalXor, (yyvsp[(1) - (3)].interm.intermTypedNode), (yyvsp[(3) - (3)].interm.intermTypedNode), (yylsp[(2) - (3)]), context->symbolTable);
  1.3014 +        if ((yyval.interm.intermTypedNode) == 0) {
  1.3015 +            context->binaryOpError((yylsp[(2) - (3)]), "^^", (yyvsp[(1) - (3)].interm.intermTypedNode)->getCompleteString(), (yyvsp[(3) - (3)].interm.intermTypedNode)->getCompleteString());
  1.3016 +            context->recover();
  1.3017 +            ConstantUnion *unionArray = new ConstantUnion[1];
  1.3018 +            unionArray->setBConst(false);
  1.3019 +            (yyval.interm.intermTypedNode) = context->intermediate.addConstantUnion(unionArray, TType(EbtBool, EbpUndefined, EvqConst), (yylsp[(2) - (3)]));
  1.3020 +        }
  1.3021 +    }
  1.3022 +    break;
  1.3023 +
  1.3024 +  case 58:
  1.3025 +
  1.3026 +    { (yyval.interm.intermTypedNode) = (yyvsp[(1) - (1)].interm.intermTypedNode); }
  1.3027 +    break;
  1.3028 +
  1.3029 +  case 59:
  1.3030 +
  1.3031 +    {
  1.3032 +        (yyval.interm.intermTypedNode) = context->intermediate.addBinaryMath(EOpLogicalOr, (yyvsp[(1) - (3)].interm.intermTypedNode), (yyvsp[(3) - (3)].interm.intermTypedNode), (yylsp[(2) - (3)]), context->symbolTable);
  1.3033 +        if ((yyval.interm.intermTypedNode) == 0) {
  1.3034 +            context->binaryOpError((yylsp[(2) - (3)]), "||", (yyvsp[(1) - (3)].interm.intermTypedNode)->getCompleteString(), (yyvsp[(3) - (3)].interm.intermTypedNode)->getCompleteString());
  1.3035 +            context->recover();
  1.3036 +            ConstantUnion *unionArray = new ConstantUnion[1];
  1.3037 +            unionArray->setBConst(false);
  1.3038 +            (yyval.interm.intermTypedNode) = context->intermediate.addConstantUnion(unionArray, TType(EbtBool, EbpUndefined, EvqConst), (yylsp[(2) - (3)]));
  1.3039 +        }
  1.3040 +    }
  1.3041 +    break;
  1.3042 +
  1.3043 +  case 60:
  1.3044 +
  1.3045 +    { (yyval.interm.intermTypedNode) = (yyvsp[(1) - (1)].interm.intermTypedNode); }
  1.3046 +    break;
  1.3047 +
  1.3048 +  case 61:
  1.3049 +
  1.3050 +    {
  1.3051 +       if (context->boolErrorCheck((yylsp[(2) - (5)]), (yyvsp[(1) - (5)].interm.intermTypedNode)))
  1.3052 +            context->recover();
  1.3053 +
  1.3054 +        (yyval.interm.intermTypedNode) = context->intermediate.addSelection((yyvsp[(1) - (5)].interm.intermTypedNode), (yyvsp[(3) - (5)].interm.intermTypedNode), (yyvsp[(5) - (5)].interm.intermTypedNode), (yylsp[(2) - (5)]));
  1.3055 +        if ((yyvsp[(3) - (5)].interm.intermTypedNode)->getType() != (yyvsp[(5) - (5)].interm.intermTypedNode)->getType())
  1.3056 +            (yyval.interm.intermTypedNode) = 0;
  1.3057 +
  1.3058 +        if ((yyval.interm.intermTypedNode) == 0) {
  1.3059 +            context->binaryOpError((yylsp[(2) - (5)]), ":", (yyvsp[(3) - (5)].interm.intermTypedNode)->getCompleteString(), (yyvsp[(5) - (5)].interm.intermTypedNode)->getCompleteString());
  1.3060 +            context->recover();
  1.3061 +            (yyval.interm.intermTypedNode) = (yyvsp[(5) - (5)].interm.intermTypedNode);
  1.3062 +        }
  1.3063 +    }
  1.3064 +    break;
  1.3065 +
  1.3066 +  case 62:
  1.3067 +
  1.3068 +    { (yyval.interm.intermTypedNode) = (yyvsp[(1) - (1)].interm.intermTypedNode); }
  1.3069 +    break;
  1.3070 +
  1.3071 +  case 63:
  1.3072 +
  1.3073 +    {
  1.3074 +        if (context->lValueErrorCheck((yylsp[(2) - (3)]), "assign", (yyvsp[(1) - (3)].interm.intermTypedNode)))
  1.3075 +            context->recover();
  1.3076 +        (yyval.interm.intermTypedNode) = context->intermediate.addAssign((yyvsp[(2) - (3)].interm).op, (yyvsp[(1) - (3)].interm.intermTypedNode), (yyvsp[(3) - (3)].interm.intermTypedNode), (yylsp[(2) - (3)]));
  1.3077 +        if ((yyval.interm.intermTypedNode) == 0) {
  1.3078 +            context->assignError((yylsp[(2) - (3)]), "assign", (yyvsp[(1) - (3)].interm.intermTypedNode)->getCompleteString(), (yyvsp[(3) - (3)].interm.intermTypedNode)->getCompleteString());
  1.3079 +            context->recover();
  1.3080 +            (yyval.interm.intermTypedNode) = (yyvsp[(1) - (3)].interm.intermTypedNode);
  1.3081 +        }
  1.3082 +    }
  1.3083 +    break;
  1.3084 +
  1.3085 +  case 64:
  1.3086 +
  1.3087 +    { (yyval.interm).op = EOpAssign; }
  1.3088 +    break;
  1.3089 +
  1.3090 +  case 65:
  1.3091 +
  1.3092 +    { (yyval.interm).op = EOpMulAssign; }
  1.3093 +    break;
  1.3094 +
  1.3095 +  case 66:
  1.3096 +
  1.3097 +    { (yyval.interm).op = EOpDivAssign; }
  1.3098 +    break;
  1.3099 +
  1.3100 +  case 67:
  1.3101 +
  1.3102 +    { (yyval.interm).op = EOpAddAssign; }
  1.3103 +    break;
  1.3104 +
  1.3105 +  case 68:
  1.3106 +
  1.3107 +    { (yyval.interm).op = EOpSubAssign; }
  1.3108 +    break;
  1.3109 +
  1.3110 +  case 69:
  1.3111 +
  1.3112 +    {
  1.3113 +        (yyval.interm.intermTypedNode) = (yyvsp[(1) - (1)].interm.intermTypedNode);
  1.3114 +    }
  1.3115 +    break;
  1.3116 +
  1.3117 +  case 70:
  1.3118 +
  1.3119 +    {
  1.3120 +        (yyval.interm.intermTypedNode) = context->intermediate.addComma((yyvsp[(1) - (3)].interm.intermTypedNode), (yyvsp[(3) - (3)].interm.intermTypedNode), (yylsp[(2) - (3)]));
  1.3121 +        if ((yyval.interm.intermTypedNode) == 0) {
  1.3122 +            context->binaryOpError((yylsp[(2) - (3)]), ",", (yyvsp[(1) - (3)].interm.intermTypedNode)->getCompleteString(), (yyvsp[(3) - (3)].interm.intermTypedNode)->getCompleteString());
  1.3123 +            context->recover();
  1.3124 +            (yyval.interm.intermTypedNode) = (yyvsp[(3) - (3)].interm.intermTypedNode);
  1.3125 +        }
  1.3126 +    }
  1.3127 +    break;
  1.3128 +
  1.3129 +  case 71:
  1.3130 +
  1.3131 +    {
  1.3132 +        if (context->constErrorCheck((yyvsp[(1) - (1)].interm.intermTypedNode)))
  1.3133 +            context->recover();
  1.3134 +        (yyval.interm.intermTypedNode) = (yyvsp[(1) - (1)].interm.intermTypedNode);
  1.3135 +    }
  1.3136 +    break;
  1.3137 +
  1.3138 +  case 72:
  1.3139 +
  1.3140 +    {
  1.3141 +        TFunction &function = *((yyvsp[(1) - (2)].interm).function);
  1.3142 +        
  1.3143 +        TIntermAggregate *prototype = new TIntermAggregate;
  1.3144 +        prototype->setType(function.getReturnType());
  1.3145 +        prototype->setName(function.getName());
  1.3146 +        
  1.3147 +        for (size_t i = 0; i < function.getParamCount(); i++)
  1.3148 +        {
  1.3149 +            const TParameter &param = function.getParam(i);
  1.3150 +            if (param.name != 0)
  1.3151 +            {
  1.3152 +                TVariable variable(param.name, *param.type);
  1.3153 +                
  1.3154 +                prototype = context->intermediate.growAggregate(prototype, context->intermediate.addSymbol(variable.getUniqueId(), variable.getName(), variable.getType(), (yylsp[(1) - (2)])), (yylsp[(1) - (2)]));
  1.3155 +            }
  1.3156 +            else
  1.3157 +            {
  1.3158 +                prototype = context->intermediate.growAggregate(prototype, context->intermediate.addSymbol(0, "", *param.type, (yylsp[(1) - (2)])), (yylsp[(1) - (2)]));
  1.3159 +            }
  1.3160 +        }
  1.3161 +        
  1.3162 +        prototype->setOp(EOpPrototype);
  1.3163 +        (yyval.interm.intermNode) = prototype;
  1.3164 +
  1.3165 +        context->symbolTable.pop();
  1.3166 +    }
  1.3167 +    break;
  1.3168 +
  1.3169 +  case 73:
  1.3170 +
  1.3171 +    {
  1.3172 +        if ((yyvsp[(1) - (2)].interm).intermAggregate)
  1.3173 +            (yyvsp[(1) - (2)].interm).intermAggregate->setOp(EOpDeclaration);
  1.3174 +        (yyval.interm.intermNode) = (yyvsp[(1) - (2)].interm).intermAggregate;
  1.3175 +    }
  1.3176 +    break;
  1.3177 +
  1.3178 +  case 74:
  1.3179 +
  1.3180 +    {
  1.3181 +        if (((yyvsp[(2) - (4)].interm.precision) == EbpHigh) && (context->shaderType == SH_FRAGMENT_SHADER) && !context->fragmentPrecisionHigh) {
  1.3182 +            context->error((yylsp[(1) - (4)]), "precision is not supported in fragment shader", "highp");
  1.3183 +            context->recover();
  1.3184 +        }
  1.3185 +        if (!context->symbolTable.setDefaultPrecision( (yyvsp[(3) - (4)].interm.type), (yyvsp[(2) - (4)].interm.precision) )) {
  1.3186 +            context->error((yylsp[(1) - (4)]), "illegal type argument for default precision qualifier", getBasicString((yyvsp[(3) - (4)].interm.type).type));
  1.3187 +            context->recover();
  1.3188 +        }
  1.3189 +        (yyval.interm.intermNode) = 0;
  1.3190 +    }
  1.3191 +    break;
  1.3192 +
  1.3193 +  case 75:
  1.3194 +
  1.3195 +    {
  1.3196 +        //
  1.3197 +        // Multiple declarations of the same function are allowed.
  1.3198 +        //
  1.3199 +        // If this is a definition, the definition production code will check for redefinitions
  1.3200 +        // (we don't know at this point if it's a definition or not).
  1.3201 +        //
  1.3202 +        // Redeclarations are allowed.  But, return types and parameter qualifiers must match.
  1.3203 +        //
  1.3204 +        TFunction* prevDec = static_cast<TFunction*>(context->symbolTable.find((yyvsp[(1) - (2)].interm.function)->getMangledName()));
  1.3205 +        if (prevDec) {
  1.3206 +            if (prevDec->getReturnType() != (yyvsp[(1) - (2)].interm.function)->getReturnType()) {
  1.3207 +                context->error((yylsp[(2) - (2)]), "overloaded functions must have the same return type", (yyvsp[(1) - (2)].interm.function)->getReturnType().getBasicString());
  1.3208 +                context->recover();
  1.3209 +            }
  1.3210 +            for (size_t i = 0; i < prevDec->getParamCount(); ++i) {
  1.3211 +                if (prevDec->getParam(i).type->getQualifier() != (yyvsp[(1) - (2)].interm.function)->getParam(i).type->getQualifier()) {
  1.3212 +                    context->error((yylsp[(2) - (2)]), "overloaded functions must have the same parameter qualifiers", (yyvsp[(1) - (2)].interm.function)->getParam(i).type->getQualifierString());
  1.3213 +                    context->recover();
  1.3214 +                }
  1.3215 +            }
  1.3216 +        }
  1.3217 +
  1.3218 +        //
  1.3219 +        // Check for previously declared variables using the same name.
  1.3220 +        //
  1.3221 +        TSymbol *prevSym = context->symbolTable.find((yyvsp[(1) - (2)].interm.function)->getName());
  1.3222 +        if (prevSym)
  1.3223 +        {
  1.3224 +            if (!prevSym->isFunction())
  1.3225 +            {
  1.3226 +                context->error((yylsp[(2) - (2)]), "redefinition", (yyvsp[(1) - (2)].interm.function)->getName().c_str(), "function");
  1.3227 +                context->recover();
  1.3228 +            }
  1.3229 +        }
  1.3230 +        else
  1.3231 +        {
  1.3232 +            // Insert the unmangled name to detect potential future redefinition as a variable.
  1.3233 +            context->symbolTable.getOuterLevel()->insert((yyvsp[(1) - (2)].interm.function)->getName(), *(yyvsp[(1) - (2)].interm.function));
  1.3234 +        }
  1.3235 +
  1.3236 +        //
  1.3237 +        // If this is a redeclaration, it could also be a definition,
  1.3238 +        // in which case, we want to use the variable names from this one, and not the one that's
  1.3239 +        // being redeclared.  So, pass back up this declaration, not the one in the symbol table.
  1.3240 +        //
  1.3241 +        (yyval.interm).function = (yyvsp[(1) - (2)].interm.function);
  1.3242 +
  1.3243 +        // We're at the inner scope level of the function's arguments and body statement.
  1.3244 +        // Add the function prototype to the surrounding scope instead.
  1.3245 +        context->symbolTable.getOuterLevel()->insert(*(yyval.interm).function);
  1.3246 +    }
  1.3247 +    break;
  1.3248 +
  1.3249 +  case 76:
  1.3250 +
  1.3251 +    {
  1.3252 +        (yyval.interm.function) = (yyvsp[(1) - (1)].interm.function);
  1.3253 +    }
  1.3254 +    break;
  1.3255 +
  1.3256 +  case 77:
  1.3257 +
  1.3258 +    {
  1.3259 +        (yyval.interm.function) = (yyvsp[(1) - (1)].interm.function);
  1.3260 +    }
  1.3261 +    break;
  1.3262 +
  1.3263 +  case 78:
  1.3264 +
  1.3265 +    {
  1.3266 +        // Add the parameter
  1.3267 +        (yyval.interm.function) = (yyvsp[(1) - (2)].interm.function);
  1.3268 +        if ((yyvsp[(2) - (2)].interm).param.type->getBasicType() != EbtVoid)
  1.3269 +            (yyvsp[(1) - (2)].interm.function)->addParameter((yyvsp[(2) - (2)].interm).param);
  1.3270 +        else
  1.3271 +            delete (yyvsp[(2) - (2)].interm).param.type;
  1.3272 +    }
  1.3273 +    break;
  1.3274 +
  1.3275 +  case 79:
  1.3276 +
  1.3277 +    {
  1.3278 +        //
  1.3279 +        // Only first parameter of one-parameter functions can be void
  1.3280 +        // The check for named parameters not being void is done in parameter_declarator
  1.3281 +        //
  1.3282 +        if ((yyvsp[(3) - (3)].interm).param.type->getBasicType() == EbtVoid) {
  1.3283 +            //
  1.3284 +            // This parameter > first is void
  1.3285 +            //
  1.3286 +            context->error((yylsp[(2) - (3)]), "cannot be an argument type except for '(void)'", "void");
  1.3287 +            context->recover();
  1.3288 +            delete (yyvsp[(3) - (3)].interm).param.type;
  1.3289 +        } else {
  1.3290 +            // Add the parameter
  1.3291 +            (yyval.interm.function) = (yyvsp[(1) - (3)].interm.function);
  1.3292 +            (yyvsp[(1) - (3)].interm.function)->addParameter((yyvsp[(3) - (3)].interm).param);
  1.3293 +        }
  1.3294 +    }
  1.3295 +    break;
  1.3296 +
  1.3297 +  case 80:
  1.3298 +
  1.3299 +    {
  1.3300 +        if ((yyvsp[(1) - (3)].interm.type).qualifier != EvqGlobal && (yyvsp[(1) - (3)].interm.type).qualifier != EvqTemporary) {
  1.3301 +            context->error((yylsp[(2) - (3)]), "no qualifiers allowed for function return", getQualifierString((yyvsp[(1) - (3)].interm.type).qualifier));
  1.3302 +            context->recover();
  1.3303 +        }
  1.3304 +        // make sure a sampler is not involved as well...
  1.3305 +        if (context->structQualifierErrorCheck((yylsp[(2) - (3)]), (yyvsp[(1) - (3)].interm.type)))
  1.3306 +            context->recover();
  1.3307 +
  1.3308 +        // Add the function as a prototype after parsing it (we do not support recursion)
  1.3309 +        TFunction *function;
  1.3310 +        TType type((yyvsp[(1) - (3)].interm.type));
  1.3311 +        function = new TFunction((yyvsp[(2) - (3)].lex).string, type);
  1.3312 +        (yyval.interm.function) = function;
  1.3313 +        
  1.3314 +        context->symbolTable.push();
  1.3315 +    }
  1.3316 +    break;
  1.3317 +
  1.3318 +  case 81:
  1.3319 +
  1.3320 +    {
  1.3321 +        if ((yyvsp[(1) - (2)].interm.type).type == EbtVoid) {
  1.3322 +            context->error((yylsp[(2) - (2)]), "illegal use of type 'void'", (yyvsp[(2) - (2)].lex).string->c_str());
  1.3323 +            context->recover();
  1.3324 +        }
  1.3325 +        if (context->reservedErrorCheck((yylsp[(2) - (2)]), *(yyvsp[(2) - (2)].lex).string))
  1.3326 +            context->recover();
  1.3327 +        TParameter param = {(yyvsp[(2) - (2)].lex).string, new TType((yyvsp[(1) - (2)].interm.type))};
  1.3328 +        (yyval.interm).param = param;
  1.3329 +    }
  1.3330 +    break;
  1.3331 +
  1.3332 +  case 82:
  1.3333 +
  1.3334 +    {
  1.3335 +        // Check that we can make an array out of this type
  1.3336 +        if (context->arrayTypeErrorCheck((yylsp[(3) - (5)]), (yyvsp[(1) - (5)].interm.type)))
  1.3337 +            context->recover();
  1.3338 +
  1.3339 +        if (context->reservedErrorCheck((yylsp[(2) - (5)]), *(yyvsp[(2) - (5)].lex).string))
  1.3340 +            context->recover();
  1.3341 +
  1.3342 +        int size;
  1.3343 +        if (context->arraySizeErrorCheck((yylsp[(3) - (5)]), (yyvsp[(4) - (5)].interm.intermTypedNode), size))
  1.3344 +            context->recover();
  1.3345 +        (yyvsp[(1) - (5)].interm.type).setArray(true, size);
  1.3346 +
  1.3347 +        TType* type = new TType((yyvsp[(1) - (5)].interm.type));
  1.3348 +        TParameter param = { (yyvsp[(2) - (5)].lex).string, type };
  1.3349 +        (yyval.interm).param = param;
  1.3350 +    }
  1.3351 +    break;
  1.3352 +
  1.3353 +  case 83:
  1.3354 +
  1.3355 +    {
  1.3356 +        (yyval.interm) = (yyvsp[(3) - (3)].interm);
  1.3357 +        if (context->paramErrorCheck((yylsp[(3) - (3)]), (yyvsp[(1) - (3)].interm.type).qualifier, (yyvsp[(2) - (3)].interm.qualifier), (yyval.interm).param.type))
  1.3358 +            context->recover();
  1.3359 +    }
  1.3360 +    break;
  1.3361 +
  1.3362 +  case 84:
  1.3363 +
  1.3364 +    {
  1.3365 +        (yyval.interm) = (yyvsp[(2) - (2)].interm);
  1.3366 +        if (context->parameterSamplerErrorCheck((yylsp[(2) - (2)]), (yyvsp[(1) - (2)].interm.qualifier), *(yyvsp[(2) - (2)].interm).param.type))
  1.3367 +            context->recover();
  1.3368 +        if (context->paramErrorCheck((yylsp[(2) - (2)]), EvqTemporary, (yyvsp[(1) - (2)].interm.qualifier), (yyval.interm).param.type))
  1.3369 +            context->recover();
  1.3370 +    }
  1.3371 +    break;
  1.3372 +
  1.3373 +  case 85:
  1.3374 +
  1.3375 +    {
  1.3376 +        (yyval.interm) = (yyvsp[(3) - (3)].interm);
  1.3377 +        if (context->paramErrorCheck((yylsp[(3) - (3)]), (yyvsp[(1) - (3)].interm.type).qualifier, (yyvsp[(2) - (3)].interm.qualifier), (yyval.interm).param.type))
  1.3378 +            context->recover();
  1.3379 +    }
  1.3380 +    break;
  1.3381 +
  1.3382 +  case 86:
  1.3383 +
  1.3384 +    {
  1.3385 +        (yyval.interm) = (yyvsp[(2) - (2)].interm);
  1.3386 +        if (context->parameterSamplerErrorCheck((yylsp[(2) - (2)]), (yyvsp[(1) - (2)].interm.qualifier), *(yyvsp[(2) - (2)].interm).param.type))
  1.3387 +            context->recover();
  1.3388 +        if (context->paramErrorCheck((yylsp[(2) - (2)]), EvqTemporary, (yyvsp[(1) - (2)].interm.qualifier), (yyval.interm).param.type))
  1.3389 +            context->recover();
  1.3390 +    }
  1.3391 +    break;
  1.3392 +
  1.3393 +  case 87:
  1.3394 +
  1.3395 +    {
  1.3396 +        (yyval.interm.qualifier) = EvqIn;
  1.3397 +    }
  1.3398 +    break;
  1.3399 +
  1.3400 +  case 88:
  1.3401 +
  1.3402 +    {
  1.3403 +        (yyval.interm.qualifier) = EvqIn;
  1.3404 +    }
  1.3405 +    break;
  1.3406 +
  1.3407 +  case 89:
  1.3408 +
  1.3409 +    {
  1.3410 +        (yyval.interm.qualifier) = EvqOut;
  1.3411 +    }
  1.3412 +    break;
  1.3413 +
  1.3414 +  case 90:
  1.3415 +
  1.3416 +    {
  1.3417 +        (yyval.interm.qualifier) = EvqInOut;
  1.3418 +    }
  1.3419 +    break;
  1.3420 +
  1.3421 +  case 91:
  1.3422 +
  1.3423 +    {
  1.3424 +        TParameter param = { 0, new TType((yyvsp[(1) - (1)].interm.type)) };
  1.3425 +        (yyval.interm).param = param;
  1.3426 +    }
  1.3427 +    break;
  1.3428 +
  1.3429 +  case 92:
  1.3430 +
  1.3431 +    {
  1.3432 +        (yyval.interm) = (yyvsp[(1) - (1)].interm);
  1.3433 +    }
  1.3434 +    break;
  1.3435 +
  1.3436 +  case 93:
  1.3437 +
  1.3438 +    {
  1.3439 +        if ((yyvsp[(1) - (3)].interm).type.type == EbtInvariant && !(yyvsp[(3) - (3)].lex).symbol)
  1.3440 +        {
  1.3441 +            context->error((yylsp[(3) - (3)]), "undeclared identifier declared as invariant", (yyvsp[(3) - (3)].lex).string->c_str());
  1.3442 +            context->recover();
  1.3443 +        }
  1.3444 +
  1.3445 +        TIntermSymbol* symbol = context->intermediate.addSymbol(0, *(yyvsp[(3) - (3)].lex).string, TType((yyvsp[(1) - (3)].interm).type), (yylsp[(3) - (3)]));
  1.3446 +        (yyval.interm).intermAggregate = context->intermediate.growAggregate((yyvsp[(1) - (3)].interm).intermNode, symbol, (yylsp[(3) - (3)]));
  1.3447 +        
  1.3448 +        if (context->structQualifierErrorCheck((yylsp[(3) - (3)]), (yyval.interm).type))
  1.3449 +            context->recover();
  1.3450 +
  1.3451 +        if (context->nonInitConstErrorCheck((yylsp[(3) - (3)]), *(yyvsp[(3) - (3)].lex).string, (yyval.interm).type, false))
  1.3452 +            context->recover();
  1.3453 +
  1.3454 +        TVariable* variable = 0;
  1.3455 +        if (context->nonInitErrorCheck((yylsp[(3) - (3)]), *(yyvsp[(3) - (3)].lex).string, (yyval.interm).type, variable))
  1.3456 +            context->recover();
  1.3457 +        if (symbol && variable)
  1.3458 +            symbol->setId(variable->getUniqueId());
  1.3459 +    }
  1.3460 +    break;
  1.3461 +
  1.3462 +  case 94:
  1.3463 +
  1.3464 +    {
  1.3465 +        if (context->structQualifierErrorCheck((yylsp[(3) - (5)]), (yyvsp[(1) - (5)].interm).type))
  1.3466 +            context->recover();
  1.3467 +
  1.3468 +        if (context->nonInitConstErrorCheck((yylsp[(3) - (5)]), *(yyvsp[(3) - (5)].lex).string, (yyvsp[(1) - (5)].interm).type, true))
  1.3469 +            context->recover();
  1.3470 +
  1.3471 +        (yyval.interm) = (yyvsp[(1) - (5)].interm);
  1.3472 +
  1.3473 +        if (context->arrayTypeErrorCheck((yylsp[(4) - (5)]), (yyvsp[(1) - (5)].interm).type) || context->arrayQualifierErrorCheck((yylsp[(4) - (5)]), (yyvsp[(1) - (5)].interm).type))
  1.3474 +            context->recover();
  1.3475 +        else {
  1.3476 +            (yyvsp[(1) - (5)].interm).type.setArray(true);
  1.3477 +            TVariable* variable;
  1.3478 +            if (context->arrayErrorCheck((yylsp[(4) - (5)]), *(yyvsp[(3) - (5)].lex).string, (yyvsp[(1) - (5)].interm).type, variable))
  1.3479 +                context->recover();
  1.3480 +        }
  1.3481 +    }
  1.3482 +    break;
  1.3483 +
  1.3484 +  case 95:
  1.3485 +
  1.3486 +    {
  1.3487 +        if (context->structQualifierErrorCheck((yylsp[(3) - (6)]), (yyvsp[(1) - (6)].interm).type))
  1.3488 +            context->recover();
  1.3489 +
  1.3490 +        if (context->nonInitConstErrorCheck((yylsp[(3) - (6)]), *(yyvsp[(3) - (6)].lex).string, (yyvsp[(1) - (6)].interm).type, true))
  1.3491 +            context->recover();
  1.3492 +
  1.3493 +        (yyval.interm) = (yyvsp[(1) - (6)].interm);
  1.3494 +
  1.3495 +        if (context->arrayTypeErrorCheck((yylsp[(4) - (6)]), (yyvsp[(1) - (6)].interm).type) || context->arrayQualifierErrorCheck((yylsp[(4) - (6)]), (yyvsp[(1) - (6)].interm).type))
  1.3496 +            context->recover();
  1.3497 +        else {
  1.3498 +            int size;
  1.3499 +            if (context->arraySizeErrorCheck((yylsp[(4) - (6)]), (yyvsp[(5) - (6)].interm.intermTypedNode), size))
  1.3500 +                context->recover();
  1.3501 +            (yyvsp[(1) - (6)].interm).type.setArray(true, size);
  1.3502 +            TVariable* variable = 0;
  1.3503 +            if (context->arrayErrorCheck((yylsp[(4) - (6)]), *(yyvsp[(3) - (6)].lex).string, (yyvsp[(1) - (6)].interm).type, variable))
  1.3504 +                context->recover();
  1.3505 +            TType type = TType((yyvsp[(1) - (6)].interm).type);
  1.3506 +            type.setArraySize(size);
  1.3507 +            (yyval.interm).intermAggregate = context->intermediate.growAggregate((yyvsp[(1) - (6)].interm).intermNode, context->intermediate.addSymbol(variable ? variable->getUniqueId() : 0, *(yyvsp[(3) - (6)].lex).string, type, (yylsp[(3) - (6)])), (yylsp[(3) - (6)]));
  1.3508 +        }
  1.3509 +    }
  1.3510 +    break;
  1.3511 +
  1.3512 +  case 96:
  1.3513 +
  1.3514 +    {
  1.3515 +        if (context->structQualifierErrorCheck((yylsp[(3) - (5)]), (yyvsp[(1) - (5)].interm).type))
  1.3516 +            context->recover();
  1.3517 +
  1.3518 +        (yyval.interm) = (yyvsp[(1) - (5)].interm);
  1.3519 +
  1.3520 +        TIntermNode* intermNode;
  1.3521 +        if (!context->executeInitializer((yylsp[(3) - (5)]), *(yyvsp[(3) - (5)].lex).string, (yyvsp[(1) - (5)].interm).type, (yyvsp[(5) - (5)].interm.intermTypedNode), intermNode)) {
  1.3522 +            //
  1.3523 +            // build the intermediate representation
  1.3524 +            //
  1.3525 +            if (intermNode)
  1.3526 +        (yyval.interm).intermAggregate = context->intermediate.growAggregate((yyvsp[(1) - (5)].interm).intermNode, intermNode, (yylsp[(4) - (5)]));
  1.3527 +            else
  1.3528 +                (yyval.interm).intermAggregate = (yyvsp[(1) - (5)].interm).intermAggregate;
  1.3529 +        } else {
  1.3530 +            context->recover();
  1.3531 +            (yyval.interm).intermAggregate = 0;
  1.3532 +        }
  1.3533 +    }
  1.3534 +    break;
  1.3535 +
  1.3536 +  case 97:
  1.3537 +
  1.3538 +    {
  1.3539 +        (yyval.interm).type = (yyvsp[(1) - (1)].interm.type);
  1.3540 +        (yyval.interm).intermAggregate = context->intermediate.makeAggregate(context->intermediate.addSymbol(0, "", TType((yyvsp[(1) - (1)].interm.type)), (yylsp[(1) - (1)])), (yylsp[(1) - (1)]));
  1.3541 +    }
  1.3542 +    break;
  1.3543 +
  1.3544 +  case 98:
  1.3545 +
  1.3546 +    {
  1.3547 +        TIntermSymbol* symbol = context->intermediate.addSymbol(0, *(yyvsp[(2) - (2)].lex).string, TType((yyvsp[(1) - (2)].interm.type)), (yylsp[(2) - (2)]));
  1.3548 +        (yyval.interm).intermAggregate = context->intermediate.makeAggregate(symbol, (yylsp[(2) - (2)]));
  1.3549 +        
  1.3550 +        if (context->structQualifierErrorCheck((yylsp[(2) - (2)]), (yyval.interm).type))
  1.3551 +            context->recover();
  1.3552 +
  1.3553 +        if (context->nonInitConstErrorCheck((yylsp[(2) - (2)]), *(yyvsp[(2) - (2)].lex).string, (yyval.interm).type, false))
  1.3554 +            context->recover();
  1.3555 +            
  1.3556 +            (yyval.interm).type = (yyvsp[(1) - (2)].interm.type);
  1.3557 +
  1.3558 +        TVariable* variable = 0;
  1.3559 +        if (context->nonInitErrorCheck((yylsp[(2) - (2)]), *(yyvsp[(2) - (2)].lex).string, (yyval.interm).type, variable))
  1.3560 +            context->recover();
  1.3561 +        if (variable && symbol)
  1.3562 +            symbol->setId(variable->getUniqueId());
  1.3563 +    }
  1.3564 +    break;
  1.3565 +
  1.3566 +  case 99:
  1.3567 +
  1.3568 +    {
  1.3569 +        context->error((yylsp[(2) - (4)]), "unsized array declarations not supported", (yyvsp[(2) - (4)].lex).string->c_str());
  1.3570 +        context->recover();
  1.3571 +
  1.3572 +        TIntermSymbol* symbol = context->intermediate.addSymbol(0, *(yyvsp[(2) - (4)].lex).string, TType((yyvsp[(1) - (4)].interm.type)), (yylsp[(2) - (4)]));
  1.3573 +        (yyval.interm).intermAggregate = context->intermediate.makeAggregate(symbol, (yylsp[(2) - (4)]));
  1.3574 +        (yyval.interm).type = (yyvsp[(1) - (4)].interm.type);
  1.3575 +    }
  1.3576 +    break;
  1.3577 +
  1.3578 +  case 100:
  1.3579 +
  1.3580 +    {
  1.3581 +        TType type = TType((yyvsp[(1) - (5)].interm.type));
  1.3582 +        int size;
  1.3583 +        if (context->arraySizeErrorCheck((yylsp[(2) - (5)]), (yyvsp[(4) - (5)].interm.intermTypedNode), size))
  1.3584 +            context->recover();
  1.3585 +        type.setArraySize(size);
  1.3586 +        TIntermSymbol* symbol = context->intermediate.addSymbol(0, *(yyvsp[(2) - (5)].lex).string, type, (yylsp[(2) - (5)]));
  1.3587 +        (yyval.interm).intermAggregate = context->intermediate.makeAggregate(symbol, (yylsp[(2) - (5)]));
  1.3588 +        
  1.3589 +        if (context->structQualifierErrorCheck((yylsp[(2) - (5)]), (yyvsp[(1) - (5)].interm.type)))
  1.3590 +            context->recover();
  1.3591 +
  1.3592 +        if (context->nonInitConstErrorCheck((yylsp[(2) - (5)]), *(yyvsp[(2) - (5)].lex).string, (yyvsp[(1) - (5)].interm.type), true))
  1.3593 +            context->recover();
  1.3594 +
  1.3595 +        (yyval.interm).type = (yyvsp[(1) - (5)].interm.type);
  1.3596 +
  1.3597 +        if (context->arrayTypeErrorCheck((yylsp[(3) - (5)]), (yyvsp[(1) - (5)].interm.type)) || context->arrayQualifierErrorCheck((yylsp[(3) - (5)]), (yyvsp[(1) - (5)].interm.type)))
  1.3598 +            context->recover();
  1.3599 +        else {
  1.3600 +            int size;
  1.3601 +            if (context->arraySizeErrorCheck((yylsp[(3) - (5)]), (yyvsp[(4) - (5)].interm.intermTypedNode), size))
  1.3602 +                context->recover();
  1.3603 +
  1.3604 +            (yyvsp[(1) - (5)].interm.type).setArray(true, size);
  1.3605 +            TVariable* variable = 0;
  1.3606 +            if (context->arrayErrorCheck((yylsp[(3) - (5)]), *(yyvsp[(2) - (5)].lex).string, (yyvsp[(1) - (5)].interm.type), variable))
  1.3607 +                context->recover();
  1.3608 +            if (variable && symbol)
  1.3609 +                symbol->setId(variable->getUniqueId());
  1.3610 +        }
  1.3611 +    }
  1.3612 +    break;
  1.3613 +
  1.3614 +  case 101:
  1.3615 +
  1.3616 +    {
  1.3617 +        if (context->structQualifierErrorCheck((yylsp[(2) - (4)]), (yyvsp[(1) - (4)].interm.type)))
  1.3618 +            context->recover();
  1.3619 +
  1.3620 +        (yyval.interm).type = (yyvsp[(1) - (4)].interm.type);
  1.3621 +
  1.3622 +        TIntermNode* intermNode;
  1.3623 +        if (!context->executeInitializer((yylsp[(2) - (4)]), *(yyvsp[(2) - (4)].lex).string, (yyvsp[(1) - (4)].interm.type), (yyvsp[(4) - (4)].interm.intermTypedNode), intermNode)) {
  1.3624 +        //
  1.3625 +        // Build intermediate representation
  1.3626 +        //
  1.3627 +            if(intermNode)
  1.3628 +                (yyval.interm).intermAggregate = context->intermediate.makeAggregate(intermNode, (yylsp[(3) - (4)]));
  1.3629 +            else
  1.3630 +                (yyval.interm).intermAggregate = 0;
  1.3631 +        } else {
  1.3632 +            context->recover();
  1.3633 +            (yyval.interm).intermAggregate = 0;
  1.3634 +        }
  1.3635 +    }
  1.3636 +    break;
  1.3637 +
  1.3638 +  case 102:
  1.3639 +
  1.3640 +    {
  1.3641 +        VERTEX_ONLY("invariant declaration", (yylsp[(1) - (2)]));
  1.3642 +        if (context->globalErrorCheck((yylsp[(1) - (2)]), context->symbolTable.atGlobalLevel(), "invariant varying"))
  1.3643 +            context->recover();
  1.3644 +        (yyval.interm).type.setBasic(EbtInvariant, EvqInvariantVaryingOut, (yylsp[(2) - (2)]));
  1.3645 +        if (!(yyvsp[(2) - (2)].lex).symbol)
  1.3646 +        {
  1.3647 +            context->error((yylsp[(2) - (2)]), "undeclared identifier declared as invariant", (yyvsp[(2) - (2)].lex).string->c_str());
  1.3648 +            context->recover();
  1.3649 +            
  1.3650 +            (yyval.interm).intermAggregate = 0;
  1.3651 +        }
  1.3652 +        else
  1.3653 +        {
  1.3654 +            TIntermSymbol *symbol = context->intermediate.addSymbol(0, *(yyvsp[(2) - (2)].lex).string, TType((yyval.interm).type), (yylsp[(2) - (2)]));
  1.3655 +            (yyval.interm).intermAggregate = context->intermediate.makeAggregate(symbol, (yylsp[(2) - (2)]));
  1.3656 +        }
  1.3657 +    }
  1.3658 +    break;
  1.3659 +
  1.3660 +  case 103:
  1.3661 +
  1.3662 +    {
  1.3663 +        (yyval.interm.type) = (yyvsp[(1) - (1)].interm.type);
  1.3664 +
  1.3665 +        if ((yyvsp[(1) - (1)].interm.type).array) {
  1.3666 +            context->error((yylsp[(1) - (1)]), "not supported", "first-class array");
  1.3667 +            context->recover();
  1.3668 +            (yyvsp[(1) - (1)].interm.type).setArray(false);
  1.3669 +        }
  1.3670 +    }
  1.3671 +    break;
  1.3672 +
  1.3673 +  case 104:
  1.3674 +
  1.3675 +    {
  1.3676 +        if ((yyvsp[(2) - (2)].interm.type).array) {
  1.3677 +            context->error((yylsp[(2) - (2)]), "not supported", "first-class array");
  1.3678 +            context->recover();
  1.3679 +            (yyvsp[(2) - (2)].interm.type).setArray(false);
  1.3680 +        }
  1.3681 +
  1.3682 +        if ((yyvsp[(1) - (2)].interm.type).qualifier == EvqAttribute &&
  1.3683 +            ((yyvsp[(2) - (2)].interm.type).type == EbtBool || (yyvsp[(2) - (2)].interm.type).type == EbtInt)) {
  1.3684 +            context->error((yylsp[(2) - (2)]), "cannot be bool or int", getQualifierString((yyvsp[(1) - (2)].interm.type).qualifier));
  1.3685 +            context->recover();
  1.3686 +        }
  1.3687 +        if (((yyvsp[(1) - (2)].interm.type).qualifier == EvqVaryingIn || (yyvsp[(1) - (2)].interm.type).qualifier == EvqVaryingOut) &&
  1.3688 +            ((yyvsp[(2) - (2)].interm.type).type == EbtBool || (yyvsp[(2) - (2)].interm.type).type == EbtInt)) {
  1.3689 +            context->error((yylsp[(2) - (2)]), "cannot be bool or int", getQualifierString((yyvsp[(1) - (2)].interm.type).qualifier));
  1.3690 +            context->recover();
  1.3691 +        }
  1.3692 +        (yyval.interm.type) = (yyvsp[(2) - (2)].interm.type);
  1.3693 +        (yyval.interm.type).qualifier = (yyvsp[(1) - (2)].interm.type).qualifier;
  1.3694 +    }
  1.3695 +    break;
  1.3696 +
  1.3697 +  case 105:
  1.3698 +
  1.3699 +    {
  1.3700 +        (yyval.interm.type).setBasic(EbtVoid, EvqConst, (yylsp[(1) - (1)]));
  1.3701 +    }
  1.3702 +    break;
  1.3703 +
  1.3704 +  case 106:
  1.3705 +
  1.3706 +    {
  1.3707 +        VERTEX_ONLY("attribute", (yylsp[(1) - (1)]));
  1.3708 +        if (context->globalErrorCheck((yylsp[(1) - (1)]), context->symbolTable.atGlobalLevel(), "attribute"))
  1.3709 +            context->recover();
  1.3710 +        (yyval.interm.type).setBasic(EbtVoid, EvqAttribute, (yylsp[(1) - (1)]));
  1.3711 +    }
  1.3712 +    break;
  1.3713 +
  1.3714 +  case 107:
  1.3715 +
  1.3716 +    {
  1.3717 +        if (context->globalErrorCheck((yylsp[(1) - (1)]), context->symbolTable.atGlobalLevel(), "varying"))
  1.3718 +            context->recover();
  1.3719 +        if (context->shaderType == SH_VERTEX_SHADER)
  1.3720 +            (yyval.interm.type).setBasic(EbtVoid, EvqVaryingOut, (yylsp[(1) - (1)]));
  1.3721 +        else
  1.3722 +            (yyval.interm.type).setBasic(EbtVoid, EvqVaryingIn, (yylsp[(1) - (1)]));
  1.3723 +    }
  1.3724 +    break;
  1.3725 +
  1.3726 +  case 108:
  1.3727 +
  1.3728 +    {
  1.3729 +        if (context->globalErrorCheck((yylsp[(1) - (2)]), context->symbolTable.atGlobalLevel(), "invariant varying"))
  1.3730 +            context->recover();
  1.3731 +        if (context->shaderType == SH_VERTEX_SHADER)
  1.3732 +            (yyval.interm.type).setBasic(EbtVoid, EvqInvariantVaryingOut, (yylsp[(1) - (2)]));
  1.3733 +        else
  1.3734 +            (yyval.interm.type).setBasic(EbtVoid, EvqInvariantVaryingIn, (yylsp[(1) - (2)]));
  1.3735 +    }
  1.3736 +    break;
  1.3737 +
  1.3738 +  case 109:
  1.3739 +
  1.3740 +    {
  1.3741 +        if (context->globalErrorCheck((yylsp[(1) - (1)]), context->symbolTable.atGlobalLevel(), "uniform"))
  1.3742 +            context->recover();
  1.3743 +        (yyval.interm.type).setBasic(EbtVoid, EvqUniform, (yylsp[(1) - (1)]));
  1.3744 +    }
  1.3745 +    break;
  1.3746 +
  1.3747 +  case 110:
  1.3748 +
  1.3749 +    {
  1.3750 +        (yyval.interm.type) = (yyvsp[(1) - (1)].interm.type);
  1.3751 +
  1.3752 +        if ((yyval.interm.type).precision == EbpUndefined) {
  1.3753 +            (yyval.interm.type).precision = context->symbolTable.getDefaultPrecision((yyvsp[(1) - (1)].interm.type).type);
  1.3754 +            if (context->precisionErrorCheck((yylsp[(1) - (1)]), (yyval.interm.type).precision, (yyvsp[(1) - (1)].interm.type).type)) {
  1.3755 +                context->recover();
  1.3756 +            }
  1.3757 +        }
  1.3758 +    }
  1.3759 +    break;
  1.3760 +
  1.3761 +  case 111:
  1.3762 +
  1.3763 +    {
  1.3764 +        (yyval.interm.type) = (yyvsp[(2) - (2)].interm.type);
  1.3765 +        (yyval.interm.type).precision = (yyvsp[(1) - (2)].interm.precision);
  1.3766 +    }
  1.3767 +    break;
  1.3768 +
  1.3769 +  case 112:
  1.3770 +
  1.3771 +    {
  1.3772 +        (yyval.interm.precision) = EbpHigh;
  1.3773 +    }
  1.3774 +    break;
  1.3775 +
  1.3776 +  case 113:
  1.3777 +
  1.3778 +    {
  1.3779 +        (yyval.interm.precision) = EbpMedium;
  1.3780 +    }
  1.3781 +    break;
  1.3782 +
  1.3783 +  case 114:
  1.3784 +
  1.3785 +    {
  1.3786 +        (yyval.interm.precision) = EbpLow;
  1.3787 +    }
  1.3788 +    break;
  1.3789 +
  1.3790 +  case 115:
  1.3791 +
  1.3792 +    {
  1.3793 +        (yyval.interm.type) = (yyvsp[(1) - (1)].interm.type);
  1.3794 +    }
  1.3795 +    break;
  1.3796 +
  1.3797 +  case 116:
  1.3798 +
  1.3799 +    {
  1.3800 +        (yyval.interm.type) = (yyvsp[(1) - (4)].interm.type);
  1.3801 +
  1.3802 +        if (context->arrayTypeErrorCheck((yylsp[(2) - (4)]), (yyvsp[(1) - (4)].interm.type)))
  1.3803 +            context->recover();
  1.3804 +        else {
  1.3805 +            int size;
  1.3806 +            if (context->arraySizeErrorCheck((yylsp[(2) - (4)]), (yyvsp[(3) - (4)].interm.intermTypedNode), size))
  1.3807 +                context->recover();
  1.3808 +            (yyval.interm.type).setArray(true, size);
  1.3809 +        }
  1.3810 +    }
  1.3811 +    break;
  1.3812 +
  1.3813 +  case 117:
  1.3814 +
  1.3815 +    {
  1.3816 +        TQualifier qual = context->symbolTable.atGlobalLevel() ? EvqGlobal : EvqTemporary;
  1.3817 +        (yyval.interm.type).setBasic(EbtVoid, qual, (yylsp[(1) - (1)]));
  1.3818 +    }
  1.3819 +    break;
  1.3820 +
  1.3821 +  case 118:
  1.3822 +
  1.3823 +    {
  1.3824 +        TQualifier qual = context->symbolTable.atGlobalLevel() ? EvqGlobal : EvqTemporary;
  1.3825 +        (yyval.interm.type).setBasic(EbtFloat, qual, (yylsp[(1) - (1)]));
  1.3826 +    }
  1.3827 +    break;
  1.3828 +
  1.3829 +  case 119:
  1.3830 +
  1.3831 +    {
  1.3832 +        TQualifier qual = context->symbolTable.atGlobalLevel() ? EvqGlobal : EvqTemporary;
  1.3833 +        (yyval.interm.type).setBasic(EbtInt, qual, (yylsp[(1) - (1)]));
  1.3834 +    }
  1.3835 +    break;
  1.3836 +
  1.3837 +  case 120:
  1.3838 +
  1.3839 +    {
  1.3840 +        TQualifier qual = context->symbolTable.atGlobalLevel() ? EvqGlobal : EvqTemporary;
  1.3841 +        (yyval.interm.type).setBasic(EbtBool, qual, (yylsp[(1) - (1)]));
  1.3842 +    }
  1.3843 +    break;
  1.3844 +
  1.3845 +  case 121:
  1.3846 +
  1.3847 +    {
  1.3848 +        TQualifier qual = context->symbolTable.atGlobalLevel() ? EvqGlobal : EvqTemporary;
  1.3849 +        (yyval.interm.type).setBasic(EbtFloat, qual, (yylsp[(1) - (1)]));
  1.3850 +        (yyval.interm.type).setAggregate(2);
  1.3851 +    }
  1.3852 +    break;
  1.3853 +
  1.3854 +  case 122:
  1.3855 +
  1.3856 +    {
  1.3857 +        TQualifier qual = context->symbolTable.atGlobalLevel() ? EvqGlobal : EvqTemporary;
  1.3858 +        (yyval.interm.type).setBasic(EbtFloat, qual, (yylsp[(1) - (1)]));
  1.3859 +        (yyval.interm.type).setAggregate(3);
  1.3860 +    }
  1.3861 +    break;
  1.3862 +
  1.3863 +  case 123:
  1.3864 +
  1.3865 +    {
  1.3866 +        TQualifier qual = context->symbolTable.atGlobalLevel() ? EvqGlobal : EvqTemporary;
  1.3867 +        (yyval.interm.type).setBasic(EbtFloat, qual, (yylsp[(1) - (1)]));
  1.3868 +        (yyval.interm.type).setAggregate(4);
  1.3869 +    }
  1.3870 +    break;
  1.3871 +
  1.3872 +  case 124:
  1.3873 +
  1.3874 +    {
  1.3875 +        TQualifier qual = context->symbolTable.atGlobalLevel() ? EvqGlobal : EvqTemporary;
  1.3876 +        (yyval.interm.type).setBasic(EbtBool, qual, (yylsp[(1) - (1)]));
  1.3877 +        (yyval.interm.type).setAggregate(2);
  1.3878 +    }
  1.3879 +    break;
  1.3880 +
  1.3881 +  case 125:
  1.3882 +
  1.3883 +    {
  1.3884 +        TQualifier qual = context->symbolTable.atGlobalLevel() ? EvqGlobal : EvqTemporary;
  1.3885 +        (yyval.interm.type).setBasic(EbtBool, qual, (yylsp[(1) - (1)]));
  1.3886 +        (yyval.interm.type).setAggregate(3);
  1.3887 +    }
  1.3888 +    break;
  1.3889 +
  1.3890 +  case 126:
  1.3891 +
  1.3892 +    {
  1.3893 +        TQualifier qual = context->symbolTable.atGlobalLevel() ? EvqGlobal : EvqTemporary;
  1.3894 +        (yyval.interm.type).setBasic(EbtBool, qual, (yylsp[(1) - (1)]));
  1.3895 +        (yyval.interm.type).setAggregate(4);
  1.3896 +    }
  1.3897 +    break;
  1.3898 +
  1.3899 +  case 127:
  1.3900 +
  1.3901 +    {
  1.3902 +        TQualifier qual = context->symbolTable.atGlobalLevel() ? EvqGlobal : EvqTemporary;
  1.3903 +        (yyval.interm.type).setBasic(EbtInt, qual, (yylsp[(1) - (1)]));
  1.3904 +        (yyval.interm.type).setAggregate(2);
  1.3905 +    }
  1.3906 +    break;
  1.3907 +
  1.3908 +  case 128:
  1.3909 +
  1.3910 +    {
  1.3911 +        TQualifier qual = context->symbolTable.atGlobalLevel() ? EvqGlobal : EvqTemporary;
  1.3912 +        (yyval.interm.type).setBasic(EbtInt, qual, (yylsp[(1) - (1)]));
  1.3913 +        (yyval.interm.type).setAggregate(3);
  1.3914 +    }
  1.3915 +    break;
  1.3916 +
  1.3917 +  case 129:
  1.3918 +
  1.3919 +    {
  1.3920 +        TQualifier qual = context->symbolTable.atGlobalLevel() ? EvqGlobal : EvqTemporary;
  1.3921 +        (yyval.interm.type).setBasic(EbtInt, qual, (yylsp[(1) - (1)]));
  1.3922 +        (yyval.interm.type).setAggregate(4);
  1.3923 +    }
  1.3924 +    break;
  1.3925 +
  1.3926 +  case 130:
  1.3927 +
  1.3928 +    {
  1.3929 +        TQualifier qual = context->symbolTable.atGlobalLevel() ? EvqGlobal : EvqTemporary;
  1.3930 +        (yyval.interm.type).setBasic(EbtFloat, qual, (yylsp[(1) - (1)]));
  1.3931 +        (yyval.interm.type).setAggregate(2, true);
  1.3932 +    }
  1.3933 +    break;
  1.3934 +
  1.3935 +  case 131:
  1.3936 +
  1.3937 +    {
  1.3938 +        TQualifier qual = context->symbolTable.atGlobalLevel() ? EvqGlobal : EvqTemporary;
  1.3939 +        (yyval.interm.type).setBasic(EbtFloat, qual, (yylsp[(1) - (1)]));
  1.3940 +        (yyval.interm.type).setAggregate(3, true);
  1.3941 +    }
  1.3942 +    break;
  1.3943 +
  1.3944 +  case 132:
  1.3945 +
  1.3946 +    {
  1.3947 +        TQualifier qual = context->symbolTable.atGlobalLevel() ? EvqGlobal : EvqTemporary;
  1.3948 +        (yyval.interm.type).setBasic(EbtFloat, qual, (yylsp[(1) - (1)]));
  1.3949 +        (yyval.interm.type).setAggregate(4, true);
  1.3950 +    }
  1.3951 +    break;
  1.3952 +
  1.3953 +  case 133:
  1.3954 +
  1.3955 +    {
  1.3956 +        TQualifier qual = context->symbolTable.atGlobalLevel() ? EvqGlobal : EvqTemporary;
  1.3957 +        (yyval.interm.type).setBasic(EbtSampler2D, qual, (yylsp[(1) - (1)]));
  1.3958 +    }
  1.3959 +    break;
  1.3960 +
  1.3961 +  case 134:
  1.3962 +
  1.3963 +    {
  1.3964 +        TQualifier qual = context->symbolTable.atGlobalLevel() ? EvqGlobal : EvqTemporary;
  1.3965 +        (yyval.interm.type).setBasic(EbtSamplerCube, qual, (yylsp[(1) - (1)]));
  1.3966 +    }
  1.3967 +    break;
  1.3968 +
  1.3969 +  case 135:
  1.3970 +
  1.3971 +    {
  1.3972 +        if (!context->supportsExtension("GL_OES_EGL_image_external")) {
  1.3973 +            context->error((yylsp[(1) - (1)]), "unsupported type", "samplerExternalOES");
  1.3974 +            context->recover();
  1.3975 +        }
  1.3976 +        TQualifier qual = context->symbolTable.atGlobalLevel() ? EvqGlobal : EvqTemporary;
  1.3977 +        (yyval.interm.type).setBasic(EbtSamplerExternalOES, qual, (yylsp[(1) - (1)]));
  1.3978 +    }
  1.3979 +    break;
  1.3980 +
  1.3981 +  case 136:
  1.3982 +
  1.3983 +    {
  1.3984 +        if (!context->supportsExtension("GL_ARB_texture_rectangle")) {
  1.3985 +            context->error((yylsp[(1) - (1)]), "unsupported type", "sampler2DRect");
  1.3986 +            context->recover();
  1.3987 +        }
  1.3988 +        TQualifier qual = context->symbolTable.atGlobalLevel() ? EvqGlobal : EvqTemporary;
  1.3989 +        (yyval.interm.type).setBasic(EbtSampler2DRect, qual, (yylsp[(1) - (1)]));
  1.3990 +    }
  1.3991 +    break;
  1.3992 +
  1.3993 +  case 137:
  1.3994 +
  1.3995 +    {
  1.3996 +        (yyval.interm.type) = (yyvsp[(1) - (1)].interm.type);
  1.3997 +        (yyval.interm.type).qualifier = context->symbolTable.atGlobalLevel() ? EvqGlobal : EvqTemporary;
  1.3998 +    }
  1.3999 +    break;
  1.4000 +
  1.4001 +  case 138:
  1.4002 +
  1.4003 +    {
  1.4004 +        //
  1.4005 +        // This is for user defined type names.  The lexical phase looked up the
  1.4006 +        // type.
  1.4007 +        //
  1.4008 +        TType& structure = static_cast<TVariable*>((yyvsp[(1) - (1)].lex).symbol)->getType();
  1.4009 +        TQualifier qual = context->symbolTable.atGlobalLevel() ? EvqGlobal : EvqTemporary;
  1.4010 +        (yyval.interm.type).setBasic(EbtStruct, qual, (yylsp[(1) - (1)]));
  1.4011 +        (yyval.interm.type).userDef = &structure;
  1.4012 +    }
  1.4013 +    break;
  1.4014 +
  1.4015 +  case 139:
  1.4016 +
  1.4017 +    { if (context->enterStructDeclaration((yylsp[(2) - (3)]), *(yyvsp[(2) - (3)].lex).string)) context->recover(); }
  1.4018 +    break;
  1.4019 +
  1.4020 +  case 140:
  1.4021 +
  1.4022 +    {
  1.4023 +        if (context->reservedErrorCheck((yylsp[(2) - (6)]), *(yyvsp[(2) - (6)].lex).string))
  1.4024 +            context->recover();
  1.4025 +
  1.4026 +        TType* structure = new TType(new TStructure((yyvsp[(2) - (6)].lex).string, (yyvsp[(5) - (6)].interm.fieldList)));
  1.4027 +        TVariable* userTypeDef = new TVariable((yyvsp[(2) - (6)].lex).string, *structure, true);
  1.4028 +        if (! context->symbolTable.insert(*userTypeDef)) {
  1.4029 +            context->error((yylsp[(2) - (6)]), "redefinition", (yyvsp[(2) - (6)].lex).string->c_str(), "struct");
  1.4030 +            context->recover();
  1.4031 +        }
  1.4032 +        (yyval.interm.type).setBasic(EbtStruct, EvqTemporary, (yylsp[(1) - (6)]));
  1.4033 +        (yyval.interm.type).userDef = structure;
  1.4034 +        context->exitStructDeclaration();
  1.4035 +    }
  1.4036 +    break;
  1.4037 +
  1.4038 +  case 141:
  1.4039 +
  1.4040 +    { if (context->enterStructDeclaration((yylsp[(2) - (2)]), *(yyvsp[(2) - (2)].lex).string)) context->recover(); }
  1.4041 +    break;
  1.4042 +
  1.4043 +  case 142:
  1.4044 +
  1.4045 +    {
  1.4046 +        TType* structure = new TType(new TStructure(NewPoolTString(""), (yyvsp[(4) - (5)].interm.fieldList)));
  1.4047 +        (yyval.interm.type).setBasic(EbtStruct, EvqTemporary, (yylsp[(1) - (5)]));
  1.4048 +        (yyval.interm.type).userDef = structure;
  1.4049 +        context->exitStructDeclaration();
  1.4050 +    }
  1.4051 +    break;
  1.4052 +
  1.4053 +  case 143:
  1.4054 +
  1.4055 +    {
  1.4056 +        (yyval.interm.fieldList) = (yyvsp[(1) - (1)].interm.fieldList);
  1.4057 +    }
  1.4058 +    break;
  1.4059 +
  1.4060 +  case 144:
  1.4061 +
  1.4062 +    {
  1.4063 +        (yyval.interm.fieldList) = (yyvsp[(1) - (2)].interm.fieldList);
  1.4064 +        for (size_t i = 0; i < (yyvsp[(2) - (2)].interm.fieldList)->size(); ++i) {
  1.4065 +            TField* field = (*(yyvsp[(2) - (2)].interm.fieldList))[i];
  1.4066 +            for (size_t j = 0; j < (yyval.interm.fieldList)->size(); ++j) {
  1.4067 +                if ((*(yyval.interm.fieldList))[j]->name() == field->name()) {
  1.4068 +                    context->error((yylsp[(2) - (2)]), "duplicate field name in structure:", "struct", field->name().c_str());
  1.4069 +                    context->recover();
  1.4070 +                }
  1.4071 +            }
  1.4072 +            (yyval.interm.fieldList)->push_back(field);
  1.4073 +        }
  1.4074 +    }
  1.4075 +    break;
  1.4076 +
  1.4077 +  case 145:
  1.4078 +
  1.4079 +    {
  1.4080 +        (yyval.interm.fieldList) = (yyvsp[(2) - (3)].interm.fieldList);
  1.4081 +
  1.4082 +        if (context->voidErrorCheck((yylsp[(1) - (3)]), (*(yyvsp[(2) - (3)].interm.fieldList))[0]->name(), (yyvsp[(1) - (3)].interm.type))) {
  1.4083 +            context->recover();
  1.4084 +        }
  1.4085 +        for (unsigned int i = 0; i < (yyval.interm.fieldList)->size(); ++i) {
  1.4086 +            //
  1.4087 +            // Careful not to replace already known aspects of type, like array-ness
  1.4088 +            //
  1.4089 +            TType* type = (*(yyval.interm.fieldList))[i]->type();
  1.4090 +            type->setBasicType((yyvsp[(1) - (3)].interm.type).type);
  1.4091 +            type->setNominalSize((yyvsp[(1) - (3)].interm.type).size);
  1.4092 +            type->setMatrix((yyvsp[(1) - (3)].interm.type).matrix);
  1.4093 +            type->setPrecision((yyvsp[(1) - (3)].interm.type).precision);
  1.4094 +
  1.4095 +            // don't allow arrays of arrays
  1.4096 +            if (type->isArray()) {
  1.4097 +                if (context->arrayTypeErrorCheck((yylsp[(1) - (3)]), (yyvsp[(1) - (3)].interm.type)))
  1.4098 +                    context->recover();
  1.4099 +            }
  1.4100 +            if ((yyvsp[(1) - (3)].interm.type).array)
  1.4101 +                type->setArraySize((yyvsp[(1) - (3)].interm.type).arraySize);
  1.4102 +            if ((yyvsp[(1) - (3)].interm.type).userDef)
  1.4103 +                type->setStruct((yyvsp[(1) - (3)].interm.type).userDef->getStruct());
  1.4104 +
  1.4105 +            if (context->structNestingErrorCheck((yylsp[(1) - (3)]), *(*(yyval.interm.fieldList))[i]))
  1.4106 +                context->recover();
  1.4107 +        }
  1.4108 +    }
  1.4109 +    break;
  1.4110 +
  1.4111 +  case 146:
  1.4112 +
  1.4113 +    {
  1.4114 +        (yyval.interm.fieldList) = NewPoolTFieldList();
  1.4115 +        (yyval.interm.fieldList)->push_back((yyvsp[(1) - (1)].interm.field));
  1.4116 +    }
  1.4117 +    break;
  1.4118 +
  1.4119 +  case 147:
  1.4120 +
  1.4121 +    {
  1.4122 +        (yyval.interm.fieldList)->push_back((yyvsp[(3) - (3)].interm.field));
  1.4123 +    }
  1.4124 +    break;
  1.4125 +
  1.4126 +  case 148:
  1.4127 +
  1.4128 +    {
  1.4129 +        if (context->reservedErrorCheck((yylsp[(1) - (1)]), *(yyvsp[(1) - (1)].lex).string))
  1.4130 +            context->recover();
  1.4131 +
  1.4132 +        TType* type = new TType(EbtVoid, EbpUndefined);
  1.4133 +        (yyval.interm.field) = new TField(type, (yyvsp[(1) - (1)].lex).string);
  1.4134 +    }
  1.4135 +    break;
  1.4136 +
  1.4137 +  case 149:
  1.4138 +
  1.4139 +    {
  1.4140 +        if (context->reservedErrorCheck((yylsp[(1) - (4)]), *(yyvsp[(1) - (4)].lex).string))
  1.4141 +            context->recover();
  1.4142 +
  1.4143 +        TType* type = new TType(EbtVoid, EbpUndefined);
  1.4144 +        int size = 0;
  1.4145 +        if (context->arraySizeErrorCheck((yylsp[(3) - (4)]), (yyvsp[(3) - (4)].interm.intermTypedNode), size))
  1.4146 +            context->recover();
  1.4147 +        type->setArraySize(size);
  1.4148 +
  1.4149 +        (yyval.interm.field) = new TField(type, (yyvsp[(1) - (4)].lex).string);
  1.4150 +    }
  1.4151 +    break;
  1.4152 +
  1.4153 +  case 150:
  1.4154 +
  1.4155 +    { (yyval.interm.intermTypedNode) = (yyvsp[(1) - (1)].interm.intermTypedNode); }
  1.4156 +    break;
  1.4157 +
  1.4158 +  case 151:
  1.4159 +
  1.4160 +    { (yyval.interm.intermNode) = (yyvsp[(1) - (1)].interm.intermNode); }
  1.4161 +    break;
  1.4162 +
  1.4163 +  case 152:
  1.4164 +
  1.4165 +    { (yyval.interm.intermNode) = (yyvsp[(1) - (1)].interm.intermAggregate); }
  1.4166 +    break;
  1.4167 +
  1.4168 +  case 153:
  1.4169 +
  1.4170 +    { (yyval.interm.intermNode) = (yyvsp[(1) - (1)].interm.intermNode); }
  1.4171 +    break;
  1.4172 +
  1.4173 +  case 154:
  1.4174 +
  1.4175 +    { (yyval.interm.intermNode) = (yyvsp[(1) - (1)].interm.intermNode); }
  1.4176 +    break;
  1.4177 +
  1.4178 +  case 155:
  1.4179 +
  1.4180 +    { (yyval.interm.intermNode) = (yyvsp[(1) - (1)].interm.intermNode); }
  1.4181 +    break;
  1.4182 +
  1.4183 +  case 156:
  1.4184 +
  1.4185 +    { (yyval.interm.intermNode) = (yyvsp[(1) - (1)].interm.intermNode); }
  1.4186 +    break;
  1.4187 +
  1.4188 +  case 157:
  1.4189 +
  1.4190 +    { (yyval.interm.intermNode) = (yyvsp[(1) - (1)].interm.intermNode); }
  1.4191 +    break;
  1.4192 +
  1.4193 +  case 158:
  1.4194 +
  1.4195 +    { (yyval.interm.intermNode) = (yyvsp[(1) - (1)].interm.intermNode); }
  1.4196 +    break;
  1.4197 +
  1.4198 +  case 159:
  1.4199 +
  1.4200 +    { (yyval.interm.intermAggregate) = 0; }
  1.4201 +    break;
  1.4202 +
  1.4203 +  case 160:
  1.4204 +
  1.4205 +    { context->symbolTable.push(); }
  1.4206 +    break;
  1.4207 +
  1.4208 +  case 161:
  1.4209 +
  1.4210 +    { context->symbolTable.pop(); }
  1.4211 +    break;
  1.4212 +
  1.4213 +  case 162:
  1.4214 +
  1.4215 +    {
  1.4216 +        if ((yyvsp[(3) - (5)].interm.intermAggregate) != 0) {
  1.4217 +            (yyvsp[(3) - (5)].interm.intermAggregate)->setOp(EOpSequence);
  1.4218 +            (yyvsp[(3) - (5)].interm.intermAggregate)->setLine((yyloc));
  1.4219 +        }
  1.4220 +        (yyval.interm.intermAggregate) = (yyvsp[(3) - (5)].interm.intermAggregate);
  1.4221 +    }
  1.4222 +    break;
  1.4223 +
  1.4224 +  case 163:
  1.4225 +
  1.4226 +    { (yyval.interm.intermNode) = (yyvsp[(1) - (1)].interm.intermNode); }
  1.4227 +    break;
  1.4228 +
  1.4229 +  case 164:
  1.4230 +
  1.4231 +    { (yyval.interm.intermNode) = (yyvsp[(1) - (1)].interm.intermNode); }
  1.4232 +    break;
  1.4233 +
  1.4234 +  case 165:
  1.4235 +
  1.4236 +    { context->symbolTable.push(); }
  1.4237 +    break;
  1.4238 +
  1.4239 +  case 166:
  1.4240 +
  1.4241 +    { context->symbolTable.pop(); (yyval.interm.intermNode) = (yyvsp[(2) - (2)].interm.intermNode); }
  1.4242 +    break;
  1.4243 +
  1.4244 +  case 167:
  1.4245 +
  1.4246 +    { context->symbolTable.push(); }
  1.4247 +    break;
  1.4248 +
  1.4249 +  case 168:
  1.4250 +
  1.4251 +    { context->symbolTable.pop(); (yyval.interm.intermNode) = (yyvsp[(2) - (2)].interm.intermNode); }
  1.4252 +    break;
  1.4253 +
  1.4254 +  case 169:
  1.4255 +
  1.4256 +    {
  1.4257 +        (yyval.interm.intermNode) = 0;
  1.4258 +    }
  1.4259 +    break;
  1.4260 +
  1.4261 +  case 170:
  1.4262 +
  1.4263 +    {
  1.4264 +        if ((yyvsp[(2) - (3)].interm.intermAggregate)) {
  1.4265 +            (yyvsp[(2) - (3)].interm.intermAggregate)->setOp(EOpSequence);
  1.4266 +            (yyvsp[(2) - (3)].interm.intermAggregate)->setLine((yyloc));
  1.4267 +        }
  1.4268 +        (yyval.interm.intermNode) = (yyvsp[(2) - (3)].interm.intermAggregate);
  1.4269 +    }
  1.4270 +    break;
  1.4271 +
  1.4272 +  case 171:
  1.4273 +
  1.4274 +    {
  1.4275 +        (yyval.interm.intermAggregate) = context->intermediate.makeAggregate((yyvsp[(1) - (1)].interm.intermNode), (yyloc));
  1.4276 +    }
  1.4277 +    break;
  1.4278 +
  1.4279 +  case 172:
  1.4280 +
  1.4281 +    {
  1.4282 +        (yyval.interm.intermAggregate) = context->intermediate.growAggregate((yyvsp[(1) - (2)].interm.intermAggregate), (yyvsp[(2) - (2)].interm.intermNode), (yyloc));
  1.4283 +    }
  1.4284 +    break;
  1.4285 +
  1.4286 +  case 173:
  1.4287 +
  1.4288 +    { (yyval.interm.intermNode) = 0; }
  1.4289 +    break;
  1.4290 +
  1.4291 +  case 174:
  1.4292 +
  1.4293 +    { (yyval.interm.intermNode) = static_cast<TIntermNode*>((yyvsp[(1) - (2)].interm.intermTypedNode)); }
  1.4294 +    break;
  1.4295 +
  1.4296 +  case 175:
  1.4297 +
  1.4298 +    {
  1.4299 +        if (context->boolErrorCheck((yylsp[(1) - (5)]), (yyvsp[(3) - (5)].interm.intermTypedNode)))
  1.4300 +            context->recover();
  1.4301 +        (yyval.interm.intermNode) = context->intermediate.addSelection((yyvsp[(3) - (5)].interm.intermTypedNode), (yyvsp[(5) - (5)].interm.nodePair), (yylsp[(1) - (5)]));
  1.4302 +    }
  1.4303 +    break;
  1.4304 +
  1.4305 +  case 176:
  1.4306 +
  1.4307 +    {
  1.4308 +        (yyval.interm.nodePair).node1 = (yyvsp[(1) - (3)].interm.intermNode);
  1.4309 +        (yyval.interm.nodePair).node2 = (yyvsp[(3) - (3)].interm.intermNode);
  1.4310 +    }
  1.4311 +    break;
  1.4312 +
  1.4313 +  case 177:
  1.4314 +
  1.4315 +    {
  1.4316 +        (yyval.interm.nodePair).node1 = (yyvsp[(1) - (1)].interm.intermNode);
  1.4317 +        (yyval.interm.nodePair).node2 = 0;
  1.4318 +    }
  1.4319 +    break;
  1.4320 +
  1.4321 +  case 178:
  1.4322 +
  1.4323 +    {
  1.4324 +        (yyval.interm.intermTypedNode) = (yyvsp[(1) - (1)].interm.intermTypedNode);
  1.4325 +        if (context->boolErrorCheck((yyvsp[(1) - (1)].interm.intermTypedNode)->getLine(), (yyvsp[(1) - (1)].interm.intermTypedNode)))
  1.4326 +            context->recover();
  1.4327 +    }
  1.4328 +    break;
  1.4329 +
  1.4330 +  case 179:
  1.4331 +
  1.4332 +    {
  1.4333 +        TIntermNode* intermNode;
  1.4334 +        if (context->structQualifierErrorCheck((yylsp[(2) - (4)]), (yyvsp[(1) - (4)].interm.type)))
  1.4335 +            context->recover();
  1.4336 +        if (context->boolErrorCheck((yylsp[(2) - (4)]), (yyvsp[(1) - (4)].interm.type)))
  1.4337 +            context->recover();
  1.4338 +
  1.4339 +        if (!context->executeInitializer((yylsp[(2) - (4)]), *(yyvsp[(2) - (4)].lex).string, (yyvsp[(1) - (4)].interm.type), (yyvsp[(4) - (4)].interm.intermTypedNode), intermNode))
  1.4340 +            (yyval.interm.intermTypedNode) = (yyvsp[(4) - (4)].interm.intermTypedNode);
  1.4341 +        else {
  1.4342 +            context->recover();
  1.4343 +            (yyval.interm.intermTypedNode) = 0;
  1.4344 +        }
  1.4345 +    }
  1.4346 +    break;
  1.4347 +
  1.4348 +  case 180:
  1.4349 +
  1.4350 +    { context->symbolTable.push(); ++context->loopNestingLevel; }
  1.4351 +    break;
  1.4352 +
  1.4353 +  case 181:
  1.4354 +
  1.4355 +    {
  1.4356 +        context->symbolTable.pop();
  1.4357 +        (yyval.interm.intermNode) = context->intermediate.addLoop(ELoopWhile, 0, (yyvsp[(4) - (6)].interm.intermTypedNode), 0, (yyvsp[(6) - (6)].interm.intermNode), (yylsp[(1) - (6)]));
  1.4358 +        --context->loopNestingLevel;
  1.4359 +    }
  1.4360 +    break;
  1.4361 +
  1.4362 +  case 182:
  1.4363 +
  1.4364 +    { ++context->loopNestingLevel; }
  1.4365 +    break;
  1.4366 +
  1.4367 +  case 183:
  1.4368 +
  1.4369 +    {
  1.4370 +        if (context->boolErrorCheck((yylsp[(8) - (8)]), (yyvsp[(6) - (8)].interm.intermTypedNode)))
  1.4371 +            context->recover();
  1.4372 +
  1.4373 +        (yyval.interm.intermNode) = context->intermediate.addLoop(ELoopDoWhile, 0, (yyvsp[(6) - (8)].interm.intermTypedNode), 0, (yyvsp[(3) - (8)].interm.intermNode), (yylsp[(4) - (8)]));
  1.4374 +        --context->loopNestingLevel;
  1.4375 +    }
  1.4376 +    break;
  1.4377 +
  1.4378 +  case 184:
  1.4379 +
  1.4380 +    { context->symbolTable.push(); ++context->loopNestingLevel; }
  1.4381 +    break;
  1.4382 +
  1.4383 +  case 185:
  1.4384 +
  1.4385 +    {
  1.4386 +        context->symbolTable.pop();
  1.4387 +        (yyval.interm.intermNode) = context->intermediate.addLoop(ELoopFor, (yyvsp[(4) - (7)].interm.intermNode), reinterpret_cast<TIntermTyped*>((yyvsp[(5) - (7)].interm.nodePair).node1), reinterpret_cast<TIntermTyped*>((yyvsp[(5) - (7)].interm.nodePair).node2), (yyvsp[(7) - (7)].interm.intermNode), (yylsp[(1) - (7)]));
  1.4388 +        --context->loopNestingLevel;
  1.4389 +    }
  1.4390 +    break;
  1.4391 +
  1.4392 +  case 186:
  1.4393 +
  1.4394 +    {
  1.4395 +        (yyval.interm.intermNode) = (yyvsp[(1) - (1)].interm.intermNode);
  1.4396 +    }
  1.4397 +    break;
  1.4398 +
  1.4399 +  case 187:
  1.4400 +
  1.4401 +    {
  1.4402 +        (yyval.interm.intermNode) = (yyvsp[(1) - (1)].interm.intermNode);
  1.4403 +    }
  1.4404 +    break;
  1.4405 +
  1.4406 +  case 188:
  1.4407 +
  1.4408 +    {
  1.4409 +        (yyval.interm.intermTypedNode) = (yyvsp[(1) - (1)].interm.intermTypedNode);
  1.4410 +    }
  1.4411 +    break;
  1.4412 +
  1.4413 +  case 189:
  1.4414 +
  1.4415 +    {
  1.4416 +        (yyval.interm.intermTypedNode) = 0;
  1.4417 +    }
  1.4418 +    break;
  1.4419 +
  1.4420 +  case 190:
  1.4421 +
  1.4422 +    {
  1.4423 +        (yyval.interm.nodePair).node1 = (yyvsp[(1) - (2)].interm.intermTypedNode);
  1.4424 +        (yyval.interm.nodePair).node2 = 0;
  1.4425 +    }
  1.4426 +    break;
  1.4427 +
  1.4428 +  case 191:
  1.4429 +
  1.4430 +    {
  1.4431 +        (yyval.interm.nodePair).node1 = (yyvsp[(1) - (3)].interm.intermTypedNode);
  1.4432 +        (yyval.interm.nodePair).node2 = (yyvsp[(3) - (3)].interm.intermTypedNode);
  1.4433 +    }
  1.4434 +    break;
  1.4435 +
  1.4436 +  case 192:
  1.4437 +
  1.4438 +    {
  1.4439 +        if (context->loopNestingLevel <= 0) {
  1.4440 +            context->error((yylsp[(1) - (2)]), "continue statement only allowed in loops", "");
  1.4441 +            context->recover();
  1.4442 +        }
  1.4443 +        (yyval.interm.intermNode) = context->intermediate.addBranch(EOpContinue, (yylsp[(1) - (2)]));
  1.4444 +    }
  1.4445 +    break;
  1.4446 +
  1.4447 +  case 193:
  1.4448 +
  1.4449 +    {
  1.4450 +        if (context->loopNestingLevel <= 0) {
  1.4451 +            context->error((yylsp[(1) - (2)]), "break statement only allowed in loops", "");
  1.4452 +            context->recover();
  1.4453 +        }
  1.4454 +        (yyval.interm.intermNode) = context->intermediate.addBranch(EOpBreak, (yylsp[(1) - (2)]));
  1.4455 +    }
  1.4456 +    break;
  1.4457 +
  1.4458 +  case 194:
  1.4459 +
  1.4460 +    {
  1.4461 +        (yyval.interm.intermNode) = context->intermediate.addBranch(EOpReturn, (yylsp[(1) - (2)]));
  1.4462 +        if (context->currentFunctionType->getBasicType() != EbtVoid) {
  1.4463 +            context->error((yylsp[(1) - (2)]), "non-void function must return a value", "return");
  1.4464 +            context->recover();
  1.4465 +        }
  1.4466 +    }
  1.4467 +    break;
  1.4468 +
  1.4469 +  case 195:
  1.4470 +
  1.4471 +    {
  1.4472 +        (yyval.interm.intermNode) = context->intermediate.addBranch(EOpReturn, (yyvsp[(2) - (3)].interm.intermTypedNode), (yylsp[(1) - (3)]));
  1.4473 +        context->functionReturnsValue = true;
  1.4474 +        if (context->currentFunctionType->getBasicType() == EbtVoid) {
  1.4475 +            context->error((yylsp[(1) - (3)]), "void function cannot return a value", "return");
  1.4476 +            context->recover();
  1.4477 +        } else if (*(context->currentFunctionType) != (yyvsp[(2) - (3)].interm.intermTypedNode)->getType()) {
  1.4478 +            context->error((yylsp[(1) - (3)]), "function return is not matching type:", "return");
  1.4479 +            context->recover();
  1.4480 +        }
  1.4481 +    }
  1.4482 +    break;
  1.4483 +
  1.4484 +  case 196:
  1.4485 +
  1.4486 +    {
  1.4487 +        FRAG_ONLY("discard", (yylsp[(1) - (2)]));
  1.4488 +        (yyval.interm.intermNode) = context->intermediate.addBranch(EOpKill, (yylsp[(1) - (2)]));
  1.4489 +    }
  1.4490 +    break;
  1.4491 +
  1.4492 +  case 197:
  1.4493 +
  1.4494 +    {
  1.4495 +        (yyval.interm.intermNode) = (yyvsp[(1) - (1)].interm.intermNode);
  1.4496 +        context->treeRoot = (yyval.interm.intermNode);
  1.4497 +    }
  1.4498 +    break;
  1.4499 +
  1.4500 +  case 198:
  1.4501 +
  1.4502 +    {
  1.4503 +        (yyval.interm.intermNode) = context->intermediate.growAggregate((yyvsp[(1) - (2)].interm.intermNode), (yyvsp[(2) - (2)].interm.intermNode), (yyloc));
  1.4504 +        context->treeRoot = (yyval.interm.intermNode);
  1.4505 +    }
  1.4506 +    break;
  1.4507 +
  1.4508 +  case 199:
  1.4509 +
  1.4510 +    {
  1.4511 +        (yyval.interm.intermNode) = (yyvsp[(1) - (1)].interm.intermNode);
  1.4512 +    }
  1.4513 +    break;
  1.4514 +
  1.4515 +  case 200:
  1.4516 +
  1.4517 +    {
  1.4518 +        (yyval.interm.intermNode) = (yyvsp[(1) - (1)].interm.intermNode);
  1.4519 +    }
  1.4520 +    break;
  1.4521 +
  1.4522 +  case 201:
  1.4523 +
  1.4524 +    {
  1.4525 +        TFunction* function = (yyvsp[(1) - (1)].interm).function;
  1.4526 +        
  1.4527 +        const TSymbol *builtIn = context->symbolTable.findBuiltIn(function->getMangledName());
  1.4528 +        
  1.4529 +        if (builtIn)
  1.4530 +        {
  1.4531 +            context->error((yylsp[(1) - (1)]), "built-in functions cannot be redefined", function->getName().c_str());
  1.4532 +            context->recover();
  1.4533 +        }
  1.4534 +        
  1.4535 +        TFunction* prevDec = static_cast<TFunction*>(context->symbolTable.find(function->getMangledName()));
  1.4536 +        //
  1.4537 +        // Note:  'prevDec' could be 'function' if this is the first time we've seen function
  1.4538 +        // as it would have just been put in the symbol table.  Otherwise, we're looking up
  1.4539 +        // an earlier occurance.
  1.4540 +        //
  1.4541 +        if (prevDec->isDefined()) {
  1.4542 +            //
  1.4543 +            // Then this function already has a body.
  1.4544 +            //
  1.4545 +            context->error((yylsp[(1) - (1)]), "function already has a body", function->getName().c_str());
  1.4546 +            context->recover();
  1.4547 +        }
  1.4548 +        prevDec->setDefined();
  1.4549 +
  1.4550 +        //
  1.4551 +        // Raise error message if main function takes any parameters or return anything other than void
  1.4552 +        //
  1.4553 +        if (function->getName() == "main") {
  1.4554 +            if (function->getParamCount() > 0) {
  1.4555 +                context->error((yylsp[(1) - (1)]), "function cannot take any parameter(s)", function->getName().c_str());
  1.4556 +                context->recover();
  1.4557 +            }
  1.4558 +            if (function->getReturnType().getBasicType() != EbtVoid) {
  1.4559 +                context->error((yylsp[(1) - (1)]), "", function->getReturnType().getBasicString(), "main function cannot return a value");
  1.4560 +                context->recover();
  1.4561 +            }
  1.4562 +        }
  1.4563 +
  1.4564 +        //
  1.4565 +        // Remember the return type for later checking for RETURN statements.
  1.4566 +        //
  1.4567 +        context->currentFunctionType = &(prevDec->getReturnType());
  1.4568 +        context->functionReturnsValue = false;
  1.4569 +
  1.4570 +        //
  1.4571 +        // Insert parameters into the symbol table.
  1.4572 +        // If the parameter has no name, it's not an error, just don't insert it
  1.4573 +        // (could be used for unused args).
  1.4574 +        //
  1.4575 +        // Also, accumulate the list of parameters into the HIL, so lower level code
  1.4576 +        // knows where to find parameters.
  1.4577 +        //
  1.4578 +        TIntermAggregate* paramNodes = new TIntermAggregate;
  1.4579 +        for (size_t i = 0; i < function->getParamCount(); i++) {
  1.4580 +            const TParameter& param = function->getParam(i);
  1.4581 +            if (param.name != 0) {
  1.4582 +                TVariable *variable = new TVariable(param.name, *param.type);
  1.4583 +                //
  1.4584 +                // Insert the parameters with name in the symbol table.
  1.4585 +                //
  1.4586 +                if (! context->symbolTable.insert(*variable)) {
  1.4587 +                    context->error((yylsp[(1) - (1)]), "redefinition", variable->getName().c_str());
  1.4588 +                    context->recover();
  1.4589 +                    delete variable;
  1.4590 +                }
  1.4591 +
  1.4592 +                //
  1.4593 +                // Add the parameter to the HIL
  1.4594 +                //
  1.4595 +                paramNodes = context->intermediate.growAggregate(
  1.4596 +                                               paramNodes,
  1.4597 +                                               context->intermediate.addSymbol(variable->getUniqueId(),
  1.4598 +                                                                               variable->getName(),
  1.4599 +                                                                               variable->getType(),
  1.4600 +                                                                               (yylsp[(1) - (1)])),
  1.4601 +                                               (yylsp[(1) - (1)]));
  1.4602 +            } else {
  1.4603 +                paramNodes = context->intermediate.growAggregate(paramNodes, context->intermediate.addSymbol(0, "", *param.type, (yylsp[(1) - (1)])), (yylsp[(1) - (1)]));
  1.4604 +            }
  1.4605 +        }
  1.4606 +        context->intermediate.setAggregateOperator(paramNodes, EOpParameters, (yylsp[(1) - (1)]));
  1.4607 +        (yyvsp[(1) - (1)].interm).intermAggregate = paramNodes;
  1.4608 +        context->loopNestingLevel = 0;
  1.4609 +    }
  1.4610 +    break;
  1.4611 +
  1.4612 +  case 202:
  1.4613 +
  1.4614 +    {
  1.4615 +        //?? Check that all paths return a value if return type != void ?
  1.4616 +        //   May be best done as post process phase on intermediate code
  1.4617 +        if (context->currentFunctionType->getBasicType() != EbtVoid && ! context->functionReturnsValue) {
  1.4618 +            context->error((yylsp[(1) - (3)]), "function does not return a value:", "", (yyvsp[(1) - (3)].interm).function->getName().c_str());
  1.4619 +            context->recover();
  1.4620 +        }
  1.4621 +        
  1.4622 +        (yyval.interm.intermNode) = context->intermediate.growAggregate((yyvsp[(1) - (3)].interm).intermAggregate, (yyvsp[(3) - (3)].interm.intermNode), (yyloc));
  1.4623 +        context->intermediate.setAggregateOperator((yyval.interm.intermNode), EOpFunction, (yylsp[(1) - (3)]));
  1.4624 +        (yyval.interm.intermNode)->getAsAggregate()->setName((yyvsp[(1) - (3)].interm).function->getMangledName().c_str());
  1.4625 +        (yyval.interm.intermNode)->getAsAggregate()->setType((yyvsp[(1) - (3)].interm).function->getReturnType());
  1.4626 +
  1.4627 +        // store the pragma information for debug and optimize and other vendor specific
  1.4628 +        // information. This information can be queried from the parse tree
  1.4629 +        (yyval.interm.intermNode)->getAsAggregate()->setOptimize(context->pragma().optimize);
  1.4630 +        (yyval.interm.intermNode)->getAsAggregate()->setDebug(context->pragma().debug);
  1.4631 +
  1.4632 +        context->symbolTable.pop();
  1.4633 +    }
  1.4634 +    break;
  1.4635 +
  1.4636 +
  1.4637 +
  1.4638 +      default: break;
  1.4639 +    }
  1.4640 +  /* User semantic actions sometimes alter yychar, and that requires
  1.4641 +     that yytoken be updated with the new translation.  We take the
  1.4642 +     approach of translating immediately before every use of yytoken.
  1.4643 +     One alternative is translating here after every semantic action,
  1.4644 +     but that translation would be missed if the semantic action invokes
  1.4645 +     YYABORT, YYACCEPT, or YYERROR immediately after altering yychar or
  1.4646 +     if it invokes YYBACKUP.  In the case of YYABORT or YYACCEPT, an
  1.4647 +     incorrect destructor might then be invoked immediately.  In the
  1.4648 +     case of YYERROR or YYBACKUP, subsequent parser actions might lead
  1.4649 +     to an incorrect destructor call or verbose syntax error message
  1.4650 +     before the lookahead is translated.  */
  1.4651 +  YY_SYMBOL_PRINT ("-> $$ =", yyr1[yyn], &yyval, &yyloc);
  1.4652 +
  1.4653 +  YYPOPSTACK (yylen);
  1.4654 +  yylen = 0;
  1.4655 +  YY_STACK_PRINT (yyss, yyssp);
  1.4656 +
  1.4657 +  *++yyvsp = yyval;
  1.4658 +  *++yylsp = yyloc;
  1.4659 +
  1.4660 +  /* Now `shift' the result of the reduction.  Determine what state
  1.4661 +     that goes to, based on the state we popped back to and the rule
  1.4662 +     number reduced by.  */
  1.4663 +
  1.4664 +  yyn = yyr1[yyn];
  1.4665 +
  1.4666 +  yystate = yypgoto[yyn - YYNTOKENS] + *yyssp;
  1.4667 +  if (0 <= yystate && yystate <= YYLAST && yycheck[yystate] == *yyssp)
  1.4668 +    yystate = yytable[yystate];
  1.4669 +  else
  1.4670 +    yystate = yydefgoto[yyn - YYNTOKENS];
  1.4671 +
  1.4672 +  goto yynewstate;
  1.4673 +
  1.4674 +
  1.4675 +/*------------------------------------.
  1.4676 +| yyerrlab -- here on detecting error |
  1.4677 +`------------------------------------*/
  1.4678 +yyerrlab:
  1.4679 +  /* Make sure we have latest lookahead translation.  See comments at
  1.4680 +     user semantic actions for why this is necessary.  */
  1.4681 +  yytoken = yychar == YYEMPTY ? YYEMPTY : YYTRANSLATE (yychar);
  1.4682 +
  1.4683 +  /* If not already recovering from an error, report this error.  */
  1.4684 +  if (!yyerrstatus)
  1.4685 +    {
  1.4686 +      ++yynerrs;
  1.4687 +#if ! YYERROR_VERBOSE
  1.4688 +      yyerror (&yylloc, context, YY_("syntax error"));
  1.4689 +#else
  1.4690 +# define YYSYNTAX_ERROR yysyntax_error (&yymsg_alloc, &yymsg, \
  1.4691 +                                        yyssp, yytoken)
  1.4692 +      {
  1.4693 +        char const *yymsgp = YY_("syntax error");
  1.4694 +        int yysyntax_error_status;
  1.4695 +        yysyntax_error_status = YYSYNTAX_ERROR;
  1.4696 +        if (yysyntax_error_status == 0)
  1.4697 +          yymsgp = yymsg;
  1.4698 +        else if (yysyntax_error_status == 1)
  1.4699 +          {
  1.4700 +            if (yymsg != yymsgbuf)
  1.4701 +              YYSTACK_FREE (yymsg);
  1.4702 +            yymsg = (char *) YYSTACK_ALLOC (yymsg_alloc);
  1.4703 +            if (!yymsg)
  1.4704 +              {
  1.4705 +                yymsg = yymsgbuf;
  1.4706 +                yymsg_alloc = sizeof yymsgbuf;
  1.4707 +                yysyntax_error_status = 2;
  1.4708 +              }
  1.4709 +            else
  1.4710 +              {
  1.4711 +                yysyntax_error_status = YYSYNTAX_ERROR;
  1.4712 +                yymsgp = yymsg;
  1.4713 +              }
  1.4714 +          }
  1.4715 +        yyerror (&yylloc, context, yymsgp);
  1.4716 +        if (yysyntax_error_status == 2)
  1.4717 +          goto yyexhaustedlab;
  1.4718 +      }
  1.4719 +# undef YYSYNTAX_ERROR
  1.4720 +#endif
  1.4721 +    }
  1.4722 +
  1.4723 +  yyerror_range[1] = yylloc;
  1.4724 +
  1.4725 +  if (yyerrstatus == 3)
  1.4726 +    {
  1.4727 +      /* If just tried and failed to reuse lookahead token after an
  1.4728 +	 error, discard it.  */
  1.4729 +
  1.4730 +      if (yychar <= YYEOF)
  1.4731 +	{
  1.4732 +	  /* Return failure if at end of input.  */
  1.4733 +	  if (yychar == YYEOF)
  1.4734 +	    YYABORT;
  1.4735 +	}
  1.4736 +      else
  1.4737 +	{
  1.4738 +	  yydestruct ("Error: discarding",
  1.4739 +		      yytoken, &yylval, &yylloc, context);
  1.4740 +	  yychar = YYEMPTY;
  1.4741 +	}
  1.4742 +    }
  1.4743 +
  1.4744 +  /* Else will try to reuse lookahead token after shifting the error
  1.4745 +     token.  */
  1.4746 +  goto yyerrlab1;
  1.4747 +
  1.4748 +
  1.4749 +/*---------------------------------------------------.
  1.4750 +| yyerrorlab -- error raised explicitly by YYERROR.  |
  1.4751 +`---------------------------------------------------*/
  1.4752 +yyerrorlab:
  1.4753 +
  1.4754 +  /* Pacify compilers like GCC when the user code never invokes
  1.4755 +     YYERROR and the label yyerrorlab therefore never appears in user
  1.4756 +     code.  */
  1.4757 +  if (/*CONSTCOND*/ 0)
  1.4758 +     goto yyerrorlab;
  1.4759 +
  1.4760 +  yyerror_range[1] = yylsp[1-yylen];
  1.4761 +  /* Do not reclaim the symbols of the rule which action triggered
  1.4762 +     this YYERROR.  */
  1.4763 +  YYPOPSTACK (yylen);
  1.4764 +  yylen = 0;
  1.4765 +  YY_STACK_PRINT (yyss, yyssp);
  1.4766 +  yystate = *yyssp;
  1.4767 +  goto yyerrlab1;
  1.4768 +
  1.4769 +
  1.4770 +/*-------------------------------------------------------------.
  1.4771 +| yyerrlab1 -- common code for both syntax error and YYERROR.  |
  1.4772 +`-------------------------------------------------------------*/
  1.4773 +yyerrlab1:
  1.4774 +  yyerrstatus = 3;	/* Each real token shifted decrements this.  */
  1.4775 +
  1.4776 +  for (;;)
  1.4777 +    {
  1.4778 +      yyn = yypact[yystate];
  1.4779 +      if (!yypact_value_is_default (yyn))
  1.4780 +	{
  1.4781 +	  yyn += YYTERROR;
  1.4782 +	  if (0 <= yyn && yyn <= YYLAST && yycheck[yyn] == YYTERROR)
  1.4783 +	    {
  1.4784 +	      yyn = yytable[yyn];
  1.4785 +	      if (0 < yyn)
  1.4786 +		break;
  1.4787 +	    }
  1.4788 +	}
  1.4789 +
  1.4790 +      /* Pop the current state because it cannot handle the error token.  */
  1.4791 +      if (yyssp == yyss)
  1.4792 +	YYABORT;
  1.4793 +
  1.4794 +      yyerror_range[1] = *yylsp;
  1.4795 +      yydestruct ("Error: popping",
  1.4796 +		  yystos[yystate], yyvsp, yylsp, context);
  1.4797 +      YYPOPSTACK (1);
  1.4798 +      yystate = *yyssp;
  1.4799 +      YY_STACK_PRINT (yyss, yyssp);
  1.4800 +    }
  1.4801 +
  1.4802 +  YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN
  1.4803 +  *++yyvsp = yylval;
  1.4804 +  YY_IGNORE_MAYBE_UNINITIALIZED_END
  1.4805 +
  1.4806 +  yyerror_range[2] = yylloc;
  1.4807 +  /* Using YYLLOC is tempting, but would change the location of
  1.4808 +     the lookahead.  YYLOC is available though.  */
  1.4809 +  YYLLOC_DEFAULT (yyloc, yyerror_range, 2);
  1.4810 +  *++yylsp = yyloc;
  1.4811 +
  1.4812 +  /* Shift the error token.  */
  1.4813 +  YY_SYMBOL_PRINT ("Shifting", yystos[yyn], yyvsp, yylsp);
  1.4814 +
  1.4815 +  yystate = yyn;
  1.4816 +  goto yynewstate;
  1.4817 +
  1.4818 +
  1.4819 +/*-------------------------------------.
  1.4820 +| yyacceptlab -- YYACCEPT comes here.  |
  1.4821 +`-------------------------------------*/
  1.4822 +yyacceptlab:
  1.4823 +  yyresult = 0;
  1.4824 +  goto yyreturn;
  1.4825 +
  1.4826 +/*-----------------------------------.
  1.4827 +| yyabortlab -- YYABORT comes here.  |
  1.4828 +`-----------------------------------*/
  1.4829 +yyabortlab:
  1.4830 +  yyresult = 1;
  1.4831 +  goto yyreturn;
  1.4832 +
  1.4833 +#if !defined yyoverflow || YYERROR_VERBOSE
  1.4834 +/*-------------------------------------------------.
  1.4835 +| yyexhaustedlab -- memory exhaustion comes here.  |
  1.4836 +`-------------------------------------------------*/
  1.4837 +yyexhaustedlab:
  1.4838 +  yyerror (&yylloc, context, YY_("memory exhausted"));
  1.4839 +  yyresult = 2;
  1.4840 +  /* Fall through.  */
  1.4841 +#endif
  1.4842 +
  1.4843 +yyreturn:
  1.4844 +  if (yychar != YYEMPTY)
  1.4845 +    {
  1.4846 +      /* Make sure we have latest lookahead translation.  See comments at
  1.4847 +         user semantic actions for why this is necessary.  */
  1.4848 +      yytoken = YYTRANSLATE (yychar);
  1.4849 +      yydestruct ("Cleanup: discarding lookahead",
  1.4850 +                  yytoken, &yylval, &yylloc, context);
  1.4851 +    }
  1.4852 +  /* Do not reclaim the symbols of the rule which action triggered
  1.4853 +     this YYABORT or YYACCEPT.  */
  1.4854 +  YYPOPSTACK (yylen);
  1.4855 +  YY_STACK_PRINT (yyss, yyssp);
  1.4856 +  while (yyssp != yyss)
  1.4857 +    {
  1.4858 +      yydestruct ("Cleanup: popping",
  1.4859 +		  yystos[*yyssp], yyvsp, yylsp, context);
  1.4860 +      YYPOPSTACK (1);
  1.4861 +    }
  1.4862 +#ifndef yyoverflow
  1.4863 +  if (yyss != yyssa)
  1.4864 +    YYSTACK_FREE (yyss);
  1.4865 +#endif
  1.4866 +#if YYERROR_VERBOSE
  1.4867 +  if (yymsg != yymsgbuf)
  1.4868 +    YYSTACK_FREE (yymsg);
  1.4869 +#endif
  1.4870 +  /* Make sure YYID is used.  */
  1.4871 +  return YYID (yyresult);
  1.4872 +}
  1.4873 +
  1.4874 +
  1.4875 +
  1.4876 +
  1.4877 +
  1.4878 +void yyerror(YYLTYPE* yylloc, TParseContext* context, const char* reason) {
  1.4879 +    context->error(*yylloc, reason, "");
  1.4880 +    context->recover();
  1.4881 +}
  1.4882 +
  1.4883 +int glslang_parse(TParseContext* context) {
  1.4884 +    return yyparse(context);
  1.4885 +}

mercurial