Bug 707555 - Update ANGLE to r901 (v1.0) to grab correctness fixes - no review
authorBenoit Jacob <bjacob@mozilla.com>
Sun, 04 Dec 2011 17:24:41 -0500
changeset 82019 66a382d48b09bebd9505d35bef6a95f996056988
parent 82018 34589711e25452bea4f751e91fe08e3032e61faa
child 82020 1a44df2a172bf6560a11815c59615890c5e2edec
push idunknown
push userunknown
push dateunknown
bugs707555
milestone11.0a1
Bug 707555 - Update ANGLE to r901 (v1.0) to grab correctness fixes - no review This is just syncing us with the upstream http://code.google.com/p/angleproject
content/canvas/test/webgl/failing_tests_windows.txt
gfx/angle/CONTRIBUTORS
gfx/angle/README.mozilla
gfx/angle/angle-intrinsic-msvc2005.patch
gfx/angle/angle-limit-identifiers-to-250-chars.patch
gfx/angle/angle-renaming-debug.patch
gfx/angle/angle-use-xmalloc.patch
gfx/angle/extensions/ANGLE_pack_reverse_row_order.txt
gfx/angle/include/EGL/eglplatform.h
gfx/angle/include/GLES2/gl2ext.h
gfx/angle/include/GLSLANG/ShaderLang.h
gfx/angle/src/common/version.h
gfx/angle/src/compiler/BaseTypes.h
gfx/angle/src/compiler/Initialize.cpp
gfx/angle/src/compiler/OutputHLSL.cpp
gfx/angle/src/compiler/OutputHLSL.h
gfx/angle/src/compiler/ParseHelper.cpp
gfx/angle/src/compiler/ShaderLang.cpp
gfx/angle/src/compiler/VariableInfo.cpp
gfx/angle/src/compiler/glslang.l
gfx/angle/src/compiler/glslang.y
gfx/angle/src/compiler/glslang_lex.cpp
gfx/angle/src/compiler/glslang_tab.cpp
gfx/angle/src/compiler/glslang_tab.h
gfx/angle/src/libEGL/Display.cpp
gfx/angle/src/libGLESv2/Context.cpp
gfx/angle/src/libGLESv2/Context.h
gfx/angle/src/libGLESv2/Renderbuffer.cpp
gfx/angle/src/libGLESv2/Texture.cpp
gfx/angle/src/libGLESv2/Texture.h
gfx/angle/src/libGLESv2/libGLESv2.cpp
--- a/content/canvas/test/webgl/failing_tests_windows.txt
+++ b/content/canvas/test/webgl/failing_tests_windows.txt
@@ -1,16 +1,14 @@
 conformance/context/context-lost-restored.html
 conformance/context/premultiplyalpha-test.html
 conformance/glsl/functions/glsl-function-atan.html
 conformance/glsl/functions/glsl-function-atan-xy.html
-conformance/glsl/functions/glsl-function-mod-gentype.html
 conformance/glsl/misc/glsl-long-variable-names.html
 conformance/glsl/misc/shader-with-256-character-identifier.frag.html
 conformance/glsl/misc/shader-with-long-line.html
 conformance/more/conformance/quickCheckAPI-S_V.html
 conformance/more/functions/uniformfArrayLen1.html
 conformance/glsl/misc/attrib-location-length-limits.html
 conformance/glsl/misc/struct-nesting-under-maximum.html
 conformance/glsl/misc/uniform-location-length-limits.html
 conformance/renderbuffers/framebuffer-object-attachment.html
-conformance/rendering/line-loop-tri-fan.html
 conformance/misc/object-deletion-behaviour.html
--- a/gfx/angle/CONTRIBUTORS
+++ b/gfx/angle/CONTRIBUTORS
@@ -10,25 +10,27 @@ TransGaming Inc.
  Nicolas Capens
  Daniel Koch
  Andrew Lewycky
  Gavriel State
  Shannon Woods
 
 Google Inc.
  Brent Austin
+ Michael Bai
  John Bauman
  Henry Bridge
  Nat Duca
  Vangelis Kokkevis
  Zhenyao Mo
  Daniel Nicoara
  Alastair Patrick
  Alok Priyadarshi
  Kenneth Russell
+ Brian Salomon
  Ben Vanik
  Adrienne Walker
 
 Mozilla Corp.
  Ehsan Akhgari
  Benoit Jacob
  Makoto Kato
  Vladimir Vukicevic
@@ -37,9 +39,11 @@ Apple Inc.
  David Kilzer
 
 Aitor Moreno <aitormoreno at gmail.com>
 Jim Hauxwell <james at dattrax.co.uk>
 ddefrostt
 timeless
 Yore Apex
 Mark Callow
+Yuriy O'Donnell
+Sam Hocevar
 
--- a/gfx/angle/README.mozilla
+++ b/gfx/angle/README.mozilla
@@ -1,11 +1,11 @@
 This is the ANGLE project, from http://code.google.com/p/angleproject/
 
-Current revision: r885
+Current revision: r901
 
 == Applied local patches ==
 
 In this order:
   angle-renaming-debug.patch - rename debug.h to compilerdebug.h to avoid conflict in our makefiles
   angle-intrinsic-msvc2005.patch - work around a MSVC 2005 compile error
   angle-limit-identifiers-to-250-chars.patch - see bug 675625
   angle-use-xmalloc.patch - see bug 680840. Can drop this patch whenever the new preprocessor lands.
--- a/gfx/angle/angle-intrinsic-msvc2005.patch
+++ b/gfx/angle/angle-intrinsic-msvc2005.patch
@@ -1,10 +1,10 @@
 # HG changeset patch
-# Parent d9b887da80f5bc18854fb3e5e43637c18d2a25ae
+# Parent 8540788b2b719f35fe3991b913d3b696f98de730
 diff --git a/gfx/angle/src/libGLESv2/Texture.cpp b/gfx/angle/src/libGLESv2/Texture.cpp
 --- a/gfx/angle/src/libGLESv2/Texture.cpp
 +++ b/gfx/angle/src/libGLESv2/Texture.cpp
 @@ -8,16 +8,22 @@
  // Texture2D and TextureCubeMap. Implements GL texture objects and related
  // functionality. [OpenGL ES 2.0.24] section 3.7 page 63.
  
  #include "libGLESv2/Texture.h"
--- a/gfx/angle/angle-limit-identifiers-to-250-chars.patch
+++ b/gfx/angle/angle-limit-identifiers-to-250-chars.patch
@@ -1,16 +1,16 @@
 # HG changeset patch
-# Parent e8b87ef36a1dae3bbd7abb13c4bb0a0bb8f5b58c
+# Parent 099e4d30cde1424e15dd9a72fb4b2589754ceaa0
 diff --git a/gfx/angle/README.mozilla b/gfx/angle/README.mozilla
 --- a/gfx/angle/README.mozilla
 +++ b/gfx/angle/README.mozilla
 @@ -2,16 +2,17 @@ This is the ANGLE project, from http://c
  
- Current revision: r802
+ Current revision: r885
  
  == Applied local patches ==
  
  In this order:
    angle-renaming-debug.patch - rename debug.h to compilerdebug.h to avoid conflict in our makefiles
    angle-intrinsic-msvc2005.patch - work around a MSVC 2005 compile error
 +  angle-limit-identifiers-to-250-chars.patch - see bug 675625
  
--- a/gfx/angle/angle-renaming-debug.patch
+++ b/gfx/angle/angle-renaming-debug.patch
@@ -1,10 +1,10 @@
 # HG changeset patch
-# Parent eae39c479485f310e937d8550afc6596aec20159
+# Parent b6f65ca6027d397ca50783d7164a6a8fa59eef4c
 diff --git a/gfx/angle/Makefile.in b/gfx/angle/Makefile.in
 --- a/gfx/angle/Makefile.in
 +++ b/gfx/angle/Makefile.in
 @@ -73,17 +73,17 @@ CPPSRCS = \
          parseConst.cpp \
          ParseHelper.cpp \
          PoolAlloc.cpp \
          QualifierAlive.cpp \
--- a/gfx/angle/angle-use-xmalloc.patch
+++ b/gfx/angle/angle-use-xmalloc.patch
@@ -1,11 +1,10 @@
 # HG changeset patch
-# Parent 85ffde53712cab3c217bbbf0c1ec9b7ec2ae8ea6
-
+# Parent 31d1c6ebb61eb118868ca924769a2fa3a50d54ef
 diff --git a/gfx/angle/Makefile.in b/gfx/angle/Makefile.in
 --- a/gfx/angle/Makefile.in
 +++ b/gfx/angle/Makefile.in
 @@ -127,16 +127,18 @@ CSRCS   = \
  	$(NULL)
  
  DEFINES += -DANGLE_USE_NSPR -DANGLE_BUILD -DCOMPILER_IMPLEMENTATION
  
new file mode 100644
--- /dev/null
+++ b/gfx/angle/extensions/ANGLE_pack_reverse_row_order.txt
@@ -0,0 +1,164 @@
+                                             
+Name
+
+    ANGLE_pack_reverse_row_order
+
+Name Strings
+
+    GL_ANGLE_pack_reverse_row_order
+
+Contact
+
+    Daniel Koch, TransGaming (daniel 'at' transgaming.com)
+
+Contributors
+
+    Brian Salomon
+    Daniel Koch
+
+Status
+
+    XXX - Not complete yet!!!
+
+Version
+
+    Last Modified Date: November 22, 2011
+    Author Revision: 1
+
+Number
+
+    XXX not yet
+
+Dependencies
+
+    OpenGL 1.5 or OpenGL ES 1.0 are required.
+
+    Some of the functionality of this extension is not supported
+    when implemented against OpenGL ES.
+
+    EXT_texture_rg interacts with this extension.
+
+    The extension is written against the OpenGL 3.2 Specification
+    (Core Profile).
+
+Overview
+
+    This extension introduces a mechanism to allow reversing the order
+    in which image rows are written into a pack destination. This
+    effectively allows an application to flip the results of a ReadPixels
+    in the y direction operation without having to render upside down.
+
+    The coordinate system of OpenGL is vertically reversed in comparison to a
+    number of other graphics systems such as native windowing APIs. Applications
+    that perform ReadPixels may have to either render to an intermediate color
+    buffer before calling ReadPixels or perform a flip in software after
+    ReadPixels. In some systems the GL can perform the row reversal during
+    ReadPixels without incurring additional cost.
+
+IP Status
+
+    No known IP claims.
+
+Issues
+
+
+New Procedures and Functions
+
+    None
+
+New Types
+
+    None
+
+New Tokens
+
+    Accepted by the <pname> parameter of PixelStore{if}, GetIntegerv(),
+    GetBooleanv(), and GetFloatv():
+
+        PACK_REVERSE_ROW_ORDER_ANGLE    0x93A4
+
+Additions to Chapter 3 of the OpenGL 3.2 Specification (Rasterization)
+
+    In Section 4.3.1 (Reading Pixels) add a row to table 4.7:
+
+        +------------------------------+---------+---------------+-------------+
+        | Parameter Name               | Type    | Initial Value | Valid Range |
+        +------------------------------+---------+---------------+-------------+
+        | PACK_REVERSE_ROW_ORDER_ANGLE | boolean | FALSE         | TRUE/FALSE  |
+        +------------------------------+---------+---------------+-------------+
+
+    In Section 4.3.1 (Reading Pixels) modify the second paragraph of subsection 
+    "Placement in Pixel Pack Buffer or Client Memory" to read:
+
+        When PACK_REVERSE_ROW_ORDER_ANGLE is FALSE groups of elements are placed
+        in memory just as they are taken from memory when transferring pixel
+        rectangles to the GL. That is, the ith group of the jth row
+        (corresponding to the ith pixel in the jth row) is placed in memory just
+        where the ith group of the jth row would be taken from when transferring
+        pixels. See Unpacking under section 3.7.2. The only difference is that
+        the storage mode parameters whose names begin with PACK_ are used
+        instead of those whose names begin with UNPACK_. If the format is RED,
+        GREEN, BLUE, or ALPHA, only the corresponding single element is written.
+        Likewise if the format is RG, RGB, or BGR, only the corresponding two or
+        three elements are written. Otherwise all the elements of each group are
+        written. When PACK_REVERSE_ROW_ORDER_ANGLE is TRUE the order of the rows
+        of elements is reversed before the data is packed. That is, the element
+        corresponding to pixel (x, y + height - 1) becomes the first element
+        packed, followed by (x + 1, y + height - 1), etc. Otherwise, pixel data
+        is packed in the same manner as when PACK_REVERSE_ROW_ORDER_ANGLE is
+        FALSE.
+
+    In Section 6.1.4 add the following sentence to the fifth paragraph
+    (beginning with "For three-dimensional and two-dimensional array
+    textures..."):
+        When PACK_REVERSE_ROW_ORDER_ANGLE is TRUE the order of rows within
+        each image are reversed without reordering the images themselves.
+
+Dependencies on OpenGL ES
+
+    If implemented for OpenGL ES, this extension behaves as specified, except:
+
+    -Delete all references to formats RED, GREEN, BLUE, RG, and BGR.
+
+    -The language about image order in Section 6.1.4 does not apply as OpenGL ES
+     does not have GetTexImage.
+
+Dependencies on EXT_texture_rg
+
+    If EXT_texture_rg is present reinsert language about formats RED and RG
+    into the OpenGL ES 2.0 specification.
+
+Errors
+
+    None
+
+New State
+                                                           Initial
+    Get Value                       Type  Get Command      Value    Description                    Sec.
+    ---------                       ----  -----------      -------  -----------                    ----
+    PACK_REVERSE_ROW_ORDER_ANGLE    B     GetIntegerv      FALSE    Pixel pack row order reversal  4.3.1
+
+New Implementation Dependent State
+
+    None
+
+Sample Code
+
+    /* Allocate space to hold the pixel data */
+    const GLvoid* pixels = malloc(width * height * 4);
+
+    /* Bind the framebuffer object to be read */
+    glBindFramebuffer(READ_FRAMEBUFFER, framebuffer);
+
+    /* Enable row order reversal */
+    glPixelStore(PACK_REVERSE_ROW_ORDER_ANGLE, TRUE);
+
+    /* The pixel data stored in pixels will be in top-down order, ready for
+     * use with a windowing system API that expects this order.
+     */
+    glReadPixels(x, y, width, height, RGBA, UNSIGNED_BYTE, pixels);
+
+Revision History
+
+    Revision 1, 2011/11/22 (Brian Salomon)
+      - First version
--- a/gfx/angle/include/EGL/eglplatform.h
+++ b/gfx/angle/include/EGL/eglplatform.h
@@ -84,26 +84,34 @@ typedef void *EGLNativeWindowType;
 typedef void *EGLNativePixmapType;
 
 #elif defined(WL_EGL_PLATFORM)
 
 typedef struct wl_display     *EGLNativeDisplayType;
 typedef struct wl_egl_pixmap  *EGLNativePixmapType;
 typedef struct wl_egl_window  *EGLNativeWindowType;
 
-#elif defined(__unix__)
+#elif defined(__unix__) && !defined(ANDROID)
 
 /* X11 (tentative)  */
 #include <X11/Xlib.h>
 #include <X11/Xutil.h>
 
 typedef Display *EGLNativeDisplayType;
 typedef Pixmap   EGLNativePixmapType;
 typedef Window   EGLNativeWindowType;
 
+#elif defined(ANDROID)
+
+struct egl_native_pixmap_t;
+
+typedef struct ANativeWindow*           EGLNativeWindowType;
+typedef struct egl_native_pixmap_t*     EGLNativePixmapType;
+typedef void*                           EGLNativeDisplayType;
+
 #else
 #error "Platform not recognized"
 #endif
 
 /* EGL 1.2 types, renamed for consistency in EGL 1.3 */
 typedef EGLNativeDisplayType NativeDisplayType;
 typedef EGLNativePixmapType  NativePixmapType;
 typedef EGLNativeWindowType  NativeWindowType;
--- a/gfx/angle/include/GLES2/gl2ext.h
+++ b/gfx/angle/include/GLES2/gl2ext.h
@@ -202,16 +202,21 @@ typedef void* GLeglImageOES;
 
 /* GL_ANGLE_framebuffer_multisample */
 #ifndef GL_ANGLE_framebuffer_multisample
 #define GL_RENDERBUFFER_SAMPLES_ANGLE                           0x8CAB
 #define GL_FRAMEBUFFER_INCOMPLETE_MULTISAMPLE_ANGLE             0x8D56
 #define GL_MAX_SAMPLES_ANGLE                                    0x8D57
 #endif
 
+/* GL_ANGLE_pack_reverse_row_order */
+#ifndef GL_ANGLE_pack_reverse_row_order
+#define GL_PACK_REVERSE_ROW_ORDER_ANGLE                         0x93A4
+#endif
+
 /* GL_ANGLE_texture_compression_dxt3 */
 #ifndef GL_ANGLE_texture_compression_dxt3
 #define GL_COMPRESSED_RGBA_S3TC_DXT3_ANGLE                      0x83F2
 #endif
 
 /* GL_ANGLE_texture_compression_dxt5 */
 #ifndef GL_ANGLE_texture_compression_dxt5
 #define GL_COMPRESSED_RGBA_S3TC_DXT5_ANGLE                      0x83F3
@@ -842,16 +847,21 @@ typedef void (GL_APIENTRYP PFNGLBLITFRAM
 #ifndef GL_ANGLE_framebuffer_multisample
 #define GL_ANGLE_framebuffer_multisample 1
 #ifdef GL_GLEXT_PROTOTYPES
 GL_APICALL void GL_APIENTRY glRenderbufferStorageMultisampleANGLE (GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height);
 #endif
 typedef void (GL_APIENTRYP PFNGLRENDERBUFFERSTORAGEMULTISAMPLEANGLEPROC) (GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height);
 #endif
 
+/* GL_ANGLE_pack_reverse_row_order */
+#ifndef GL_ANGLE_pack_reverse_row_order
+#define GL_ANGLE_pack_reverse_row_order 1
+#endif
+
 /* GL_ANGLE_texture_compression_dxt3 */
 #ifndef GL_ANGLE_texture_compression_dxt3
 #define GL_ANGLE_texture_compression_dxt3 1
 #endif
 
 /* GL_ANGLE_texture_compression_dxt5 */
 #ifndef GL_ANGLE_texture_compression_dxt5
 #define GL_ANGLE_texture_compression_dxt5 1
--- a/gfx/angle/include/GLSLANG/ShaderLang.h
+++ b/gfx/angle/include/GLSLANG/ShaderLang.h
@@ -71,17 +71,18 @@ typedef enum {
   SH_BOOL           = 0x8B56,
   SH_BOOL_VEC2      = 0x8B57,
   SH_BOOL_VEC3      = 0x8B58,
   SH_BOOL_VEC4      = 0x8B59,
   SH_FLOAT_MAT2     = 0x8B5A,
   SH_FLOAT_MAT3     = 0x8B5B,
   SH_FLOAT_MAT4     = 0x8B5C,
   SH_SAMPLER_2D     = 0x8B5E,
-  SH_SAMPLER_CUBE   = 0x8B60
+  SH_SAMPLER_CUBE   = 0x8B60,
+  SH_SAMPLER_2D_RECT_ARB = 0x8B63
 } ShDataType;
 
 typedef enum {
   SH_INFO_LOG_LENGTH             =  0x8B84,
   SH_OBJECT_CODE_LENGTH          =  0x8B88,  // GL_SHADER_SOURCE_LENGTH
   SH_ACTIVE_UNIFORMS             =  0x8B86,
   SH_ACTIVE_UNIFORM_MAX_LENGTH   =  0x8B87,
   SH_ACTIVE_ATTRIBUTES           =  0x8B89,
@@ -132,16 +133,17 @@ typedef struct
     int MaxTextureImageUnits;
     int MaxFragmentUniformVectors;
     int MaxDrawBuffers;
 
     // Extensions.
     // Set to 1 to enable the extension, else 0.
     int OES_standard_derivatives;
     int OES_EGL_image_external;
+    int ARB_texture_rectangle;
 } ShBuiltInResources;
 
 //
 // Initialize built-in resources with minimum expected values.
 //
 COMPILER_EXPORT void ShInitBuiltInResources(ShBuiltInResources* resources);
 
 //
--- a/gfx/angle/src/common/version.h
+++ b/gfx/angle/src/common/version.h
@@ -1,10 +1,10 @@
-#define MAJOR_VERSION 0
+#define MAJOR_VERSION 1
 #define MINOR_VERSION 0
 #define BUILD_VERSION 0
-#define BUILD_REVISION 885
+#define BUILD_REVISION 901
 
 #define STRINGIFY(x) #x
 #define MACRO_STRINGIFY(x) STRINGIFY(x)
 
 #define REVISION_STRING MACRO_STRINGIFY(BUILD_REVISION)
 #define VERSION_STRING MACRO_STRINGIFY(MAJOR_VERSION) "." MACRO_STRINGIFY(MINOR_VERSION) "." MACRO_STRINGIFY(BUILD_VERSION) "." MACRO_STRINGIFY(BUILD_REVISION)
--- a/gfx/angle/src/compiler/BaseTypes.h
+++ b/gfx/angle/src/compiler/BaseTypes.h
@@ -38,32 +38,34 @@ enum TBasicType
     EbtVoid,
     EbtFloat,
     EbtInt,
     EbtBool,
     EbtGuardSamplerBegin,  // non type:  see implementation of IsSampler()
     EbtSampler2D,
     EbtSamplerCube,
     EbtSamplerExternalOES,  // Only valid if OES_EGL_image_external exists.
+    EbtSampler2DRect,       // Only valid if GL_ARB_texture_rectangle exists.
     EbtGuardSamplerEnd,    // non type:  see implementation of IsSampler()
     EbtStruct,
     EbtAddress,            // should be deprecated??
 };
 
 inline const char* getBasicString(TBasicType t)
 {
     switch (t)
     {
     case EbtVoid:              return "void";              break;
     case EbtFloat:             return "float";             break;
     case EbtInt:               return "int";               break;
     case EbtBool:              return "bool";              break;
     case EbtSampler2D:         return "sampler2D";         break;
     case EbtSamplerCube:       return "samplerCube";       break;
     case EbtSamplerExternalOES: return "samplerExternalOES"; break;
+    case EbtSampler2DRect:     return "sampler2DRect";     break;
     case EbtStruct:            return "structure";         break;
     default:                   return "unknown type";
     }
 }
 
 inline bool IsSampler(TBasicType type)
 {
     return type > EbtGuardSamplerBegin && type < EbtGuardSamplerEnd;
--- a/gfx/angle/src/compiler/Initialize.cpp
+++ b/gfx/angle/src/compiler/Initialize.cpp
@@ -14,17 +14,17 @@
 
 #include "compiler/intermediate.h"
 
 //============================================================================
 //
 // Prototypes for built-in functions seen by both vertex and fragment shaders.
 //
 //============================================================================
-static TString BuiltInFunctionsCommon()
+static TString BuiltInFunctionsCommon(const ShBuiltInResources& resources)
 {
     TString s;
 
     //
     // Angle and Trigonometric Functions.
     //
     s.append(TString("float radians(float degrees);"));
     s.append(TString("vec2  radians(vec2  degrees);"));
@@ -306,16 +306,36 @@ static TString BuiltInFunctionsCommon()
     s.append(TString("bool all(bvec3 x);"));
     s.append(TString("bool all(bvec4 x);"));
 
     s.append(TString("bvec2 not(bvec2 x);"));
     s.append(TString("bvec3 not(bvec3 x);"));
     s.append(TString("bvec4 not(bvec4 x);"));
 
     //
+    // Texture Functions.
+    //
+    s.append(TString("vec4 texture2D(sampler2D sampler, vec2 coord);"));
+    s.append(TString("vec4 texture2DProj(sampler2D sampler, vec3 coord);"));
+    s.append(TString("vec4 texture2DProj(sampler2D sampler, vec4 coord);"));
+    s.append(TString("vec4 textureCube(samplerCube sampler, vec3 coord);"));
+
+    if (resources.OES_EGL_image_external) {
+        s.append(TString("vec4 texture2D(samplerExternalOES sampler, vec2 coord);"));
+        s.append(TString("vec4 texture2DProj(samplerExternalOES sampler, vec3 coord);"));
+        s.append(TString("vec4 texture2DProj(samplerExternalOES sampler, vec4 coord);"));
+    }
+
+    if (resources.ARB_texture_rectangle) {
+        s.append(TString("vec4 texture2DRect(sampler2DRect sampler, vec2 coord);"));
+        s.append(TString("vec4 texture2DRectProj(sampler2DRect sampler, vec3 coord);"));
+        s.append(TString("vec4 texture2DRectProj(sampler2DRect sampler, vec4 coord);"));
+    }
+
+    //
     // Noise functions.
     //
     //s.append(TString("float noise1(float x);"));
     //s.append(TString("float noise1(vec2  x);"));
     //s.append(TString("float noise1(vec3  x);"));
     //s.append(TString("float noise1(vec4  x);"));
 
     //s.append(TString("vec2 noise2(float x);"));
@@ -348,63 +368,41 @@ static TString BuiltInFunctionsVertex(co
     //
     // Geometric Functions.
     //
     //s.append(TString("vec4 ftransform();"));
 
     //
     // Texture Functions.
     //
-    s.append(TString("vec4 texture2D(sampler2D sampler, vec2 coord);"));
-    s.append(TString("vec4 texture2DProj(sampler2D sampler, vec3 coord);"));
-    s.append(TString("vec4 texture2DProj(sampler2D sampler, vec4 coord);"));
-    s.append(TString("vec4 textureCube(samplerCube sampler, vec3 coord);"));
-
     s.append(TString("vec4 texture2DLod(sampler2D sampler, vec2 coord, float lod);"));
     s.append(TString("vec4 texture2DProjLod(sampler2D sampler, vec3 coord, float lod);"));
     s.append(TString("vec4 texture2DProjLod(sampler2D sampler, vec4 coord, float lod);"));
     s.append(TString("vec4 textureCubeLod(samplerCube sampler, vec3 coord, float lod);"));
 
-    if (resources.OES_EGL_image_external) {
-        s.append(TString("vec4 texture2D(samplerExternalOES sampler, vec2 coord);"));
-        s.append(TString("vec4 texture2DProj(samplerExternalOES sampler, vec3 coord);"));
-        s.append(TString("vec4 texture2DProj(samplerExternalOES sampler, vec4 coord);"));
-    }
-
     return s;
 }
 
 //============================================================================
 //
 // Prototypes for built-in functions seen by fragment shaders only.
 //
 //============================================================================
 static TString BuiltInFunctionsFragment(const ShBuiltInResources& resources)
 {
     TString s;
 
     //
     // Texture Functions.
     //
-    s.append(TString("vec4 texture2D(sampler2D sampler, vec2 coord);"));
-    s.append(TString("vec4 texture2DProj(sampler2D sampler, vec3 coord);"));
-    s.append(TString("vec4 texture2DProj(sampler2D sampler, vec4 coord);"));
-    s.append(TString("vec4 textureCube(samplerCube sampler, vec3 coord);"));
-
     s.append(TString("vec4 texture2D(sampler2D sampler, vec2 coord, float bias);"));
     s.append(TString("vec4 texture2DProj(sampler2D sampler, vec3 coord, float bias);"));
     s.append(TString("vec4 texture2DProj(sampler2D sampler, vec4 coord, float bias);"));
     s.append(TString("vec4 textureCube(samplerCube sampler, vec3 coord, float bias);"));
 
-    if (resources.OES_EGL_image_external) {
-        s.append(TString("vec4 texture2D(samplerExternalOES sampler, vec2 coord);"));
-        s.append(TString("vec4 texture2DProj(samplerExternalOES sampler, vec3 coord);"));
-        s.append(TString("vec4 texture2DProj(samplerExternalOES sampler, vec4 coord);"));
-    }
-
     if (resources.OES_standard_derivatives) {
         s.append(TString("float dFdx(float p);"));
         s.append(TString("vec2  dFdx(vec2  p);"));
         s.append(TString("vec3  dFdx(vec3  p);"));
         s.append(TString("vec4  dFdx(vec4  p);"));
 
         s.append(TString("float dFdy(float p);"));
         s.append(TString("vec2  dFdy(vec2  p);"));
@@ -495,24 +493,24 @@ static TString BuiltInConstants(const Sh
 }
 
 void TBuiltIns::initialize(ShShaderType type, ShShaderSpec spec,
                            const ShBuiltInResources& resources)
 {
     switch (type) {
     case SH_FRAGMENT_SHADER:
         builtInStrings.push_back(DefaultPrecisionFragment());
-        builtInStrings.push_back(BuiltInFunctionsCommon());
+        builtInStrings.push_back(BuiltInFunctionsCommon(resources));
         builtInStrings.push_back(BuiltInFunctionsFragment(resources));
         builtInStrings.push_back(StandardUniforms());
         break;
 
     case SH_VERTEX_SHADER:
         builtInStrings.push_back(DefaultPrecisionVertex());
-        builtInStrings.push_back(BuiltInFunctionsCommon());
+        builtInStrings.push_back(BuiltInFunctionsCommon(resources));
         builtInStrings.push_back(BuiltInFunctionsVertex(resources));
         builtInStrings.push_back(StandardUniforms());
         break;
 
     default: assert(false && "Language not supported");
     }
 
     builtInStrings.push_back(BuiltInConstants(resources));
@@ -635,9 +633,11 @@ void IdentifyBuiltIns(ShShaderType type,
 
 void InitExtensionBehavior(const ShBuiltInResources& resources,
                            TExtensionBehavior& extBehavior)
 {
     if (resources.OES_standard_derivatives)
         extBehavior["GL_OES_standard_derivatives"] = EBhUndefined;
     if (resources.OES_EGL_image_external)
         extBehavior["GL_OES_EGL_image_external"] = EBhUndefined;
+    if (resources.ARB_texture_rectangle)
+        extBehavior["GL_ARB_texture_rectangle"] = EBhUndefined;
 }
--- a/gfx/angle/src/compiler/OutputHLSL.cpp
+++ b/gfx/angle/src/compiler/OutputHLSL.cpp
@@ -40,19 +40,22 @@ OutputHLSL::OutputHLSL(TParseContext &co
     mUsesTextureCubeLod = false;
     mUsesDepthRange = false;
     mUsesFragCoord = false;
     mUsesPointCoord = false;
     mUsesFrontFacing = false;
     mUsesPointSize = false;
     mUsesXor = false;
     mUsesMod1 = false;
-    mUsesMod2 = false;
-    mUsesMod3 = false;
-    mUsesMod4 = false;
+    mUsesMod2v = false;
+    mUsesMod2f = false;
+    mUsesMod3v = false;
+    mUsesMod3f = false;
+    mUsesMod4v = false;
+    mUsesMod4f = false;
     mUsesFaceforward1 = false;
     mUsesFaceforward2 = false;
     mUsesFaceforward3 = false;
     mUsesFaceforward4 = false;
     mUsesEqualMat2 = false;
     mUsesEqualMat3 = false;
     mUsesEqualMat4 = false;
     mUsesEqualVec2 = false;
@@ -474,36 +477,63 @@ void OutputHLSL::header()
     if (mUsesMod1)
     {
         out << "float mod(float x, float y)\n"
                "{\n"
                "    return x - y * floor(x / y);\n"
                "}\n"
                "\n";
     }
-    
-    if (mUsesMod2)
+
+    if (mUsesMod2v)
+    {
+        out << "float2 mod(float2 x, float2 y)\n"
+               "{\n"
+               "    return x - y * floor(x / y);\n"
+               "}\n"
+               "\n";
+    }
+
+    if (mUsesMod2f)
     {
         out << "float2 mod(float2 x, float y)\n"
                "{\n"
                "    return x - y * floor(x / y);\n"
                "}\n"
                "\n";
     }
     
-    if (mUsesMod3)
+    if (mUsesMod3v)
+    {
+        out << "float3 mod(float3 x, float3 y)\n"
+               "{\n"
+               "    return x - y * floor(x / y);\n"
+               "}\n"
+               "\n";
+    }
+
+    if (mUsesMod3f)
     {
         out << "float3 mod(float3 x, float y)\n"
                "{\n"
                "    return x - y * floor(x / y);\n"
                "}\n"
                "\n";
     }
 
-    if (mUsesMod4)
+    if (mUsesMod4v)
+    {
+        out << "float4 mod(float4 x, float4 y)\n"
+               "{\n"
+               "    return x - y * floor(x / y);\n"
+               "}\n"
+               "\n";
+    }
+
+    if (mUsesMod4f)
     {
         out << "float4 mod(float4 x, float y)\n"
                "{\n"
                "    return x - y * floor(x / y);\n"
                "}\n"
                "\n";
     }
 
@@ -1442,22 +1472,27 @@ bool OutputHLSL::visitAggregate(Visit vi
       case EOpLessThan:         outputTriplet(visit, "(", " < ", ")");                 break;
       case EOpGreaterThan:      outputTriplet(visit, "(", " > ", ")");                 break;
       case EOpLessThanEqual:    outputTriplet(visit, "(", " <= ", ")");                break;
       case EOpGreaterThanEqual: outputTriplet(visit, "(", " >= ", ")");                break;
       case EOpVectorEqual:      outputTriplet(visit, "(", " == ", ")");                break;
       case EOpVectorNotEqual:   outputTriplet(visit, "(", " != ", ")");                break;
       case EOpMod:
         {
-            switch (node->getSequence()[0]->getAsTyped()->getNominalSize())   // Number of components in the first argument
+            // We need to look at the number of components in both arguments
+            switch (node->getSequence()[0]->getAsTyped()->getNominalSize() * 10
+                     + node->getSequence()[1]->getAsTyped()->getNominalSize())
             {
-              case 1: mUsesMod1 = true; break;
-              case 2: mUsesMod2 = true; break;
-              case 3: mUsesMod3 = true; break;
-              case 4: mUsesMod4 = true; break;
+              case 11: mUsesMod1 = true; break;
+              case 22: mUsesMod2v = true; break;
+              case 21: mUsesMod2f = true; break;
+              case 33: mUsesMod3v = true; break;
+              case 31: mUsesMod3f = true; break;
+              case 44: mUsesMod4v = true; break;
+              case 41: mUsesMod4f = true; break;
               default: UNREACHABLE();
             }
 
             outputTriplet(visit, "mod(", ", ", ")");
         }
         break;
       case EOpPow:              outputTriplet(visit, "pow(", ", ", ")");               break;
       case EOpAtan:
--- a/gfx/angle/src/compiler/OutputHLSL.h
+++ b/gfx/angle/src/compiler/OutputHLSL.h
@@ -86,19 +86,22 @@ class OutputHLSL : public TIntermTravers
     bool mUsesTextureCubeLod;
     bool mUsesDepthRange;
     bool mUsesFragCoord;
     bool mUsesPointCoord;
     bool mUsesFrontFacing;
     bool mUsesPointSize;
     bool mUsesXor;
     bool mUsesMod1;
-    bool mUsesMod2;
-    bool mUsesMod3;
-    bool mUsesMod4;
+    bool mUsesMod2v;
+    bool mUsesMod2f;
+    bool mUsesMod3v;
+    bool mUsesMod3f;
+    bool mUsesMod4v;
+    bool mUsesMod4f;
     bool mUsesFaceforward1;
     bool mUsesFaceforward2;
     bool mUsesFaceforward3;
     bool mUsesFaceforward4;
     bool mUsesEqualMat2;
     bool mUsesEqualMat3;
     bool mUsesEqualMat4;
     bool mUsesEqualVec2;
--- a/gfx/angle/src/compiler/ParseHelper.cpp
+++ b/gfx/angle/src/compiler/ParseHelper.cpp
@@ -548,17 +548,17 @@ bool TParseContext::constructorErrorChec
         return true;
     }
     
     if (op == EOpConstructStruct && !type->isArray() && int(type->getStruct()->size()) != function.getParamCount()) {
         error(line, "Number of constructor parameters does not match the number of structure fields", "constructor", "");
         return true;
     }
 
-    if (!type->isMatrix()) {
+    if (!type->isMatrix() || !matrixInMatrix) {
         if ((op != EOpConstructStruct && size != 1 && size < type->getObjectSize()) ||
             (op == EOpConstructStruct && size < type->getObjectSize())) {
             error(line, "not enough data provided for construction", "constructor", "");
             return true;
         }
     }
 
     TIntermTyped *typed = node ? node->getAsTyped() : 0;
--- a/gfx/angle/src/compiler/ShaderLang.cpp
+++ b/gfx/angle/src/compiler/ShaderLang.cpp
@@ -117,16 +117,17 @@ void ShInitBuiltInResources(ShBuiltInRes
     resources->MaxCombinedTextureImageUnits = 8;
     resources->MaxTextureImageUnits = 8;
     resources->MaxFragmentUniformVectors = 16;
     resources->MaxDrawBuffers = 1;
 
     // Extensions.
     resources->OES_standard_derivatives = 0;
     resources->OES_EGL_image_external = 0;
+    resources->ARB_texture_rectangle = 0;
 }
 
 //
 // Driver calls these to create and destroy compiler objects.
 //
 ShHandle ShConstructCompiler(ShShaderType type, ShShaderSpec spec,
                              ShShaderOutput output,
                              const ShBuiltInResources* resources)
--- a/gfx/angle/src/compiler/VariableInfo.cpp
+++ b/gfx/angle/src/compiler/VariableInfo.cpp
@@ -58,16 +58,17 @@ static ShDataType getVariableDataType(co
                 case 4: return SH_BOOL_VEC4;
                 default: UNREACHABLE();
               }
           } else {
               return SH_BOOL;
           }
       case EbtSampler2D: return SH_SAMPLER_2D;
       case EbtSamplerCube: return SH_SAMPLER_CUBE;
+      case EbtSampler2DRect: return SH_SAMPLER_2D_RECT_ARB;
       default: UNREACHABLE();
     }
     return SH_NONE;
 }
 
 static void getBuiltInVariableInfo(const TType& type,
                                    const TString& name,
                                    const TString& mappedName,
--- a/gfx/angle/src/compiler/glslang.l
+++ b/gfx/angle/src/compiler/glslang.l
@@ -116,16 +116,17 @@ O           [0-7]
 "ivec4"        { context->lexAfterType = true; return (IVEC4); }
 "bvec2"        { context->lexAfterType = true; return (BVEC2); }
 "bvec3"        { context->lexAfterType = true; return (BVEC3); }
 "bvec4"        { context->lexAfterType = true; return (BVEC4); }
 
 "sampler2D"       { context->lexAfterType = true; return SAMPLER2D; }
 "samplerCube"     { context->lexAfterType = true; return SAMPLERCUBE; }
 "samplerExternalOES" { context->lexAfterType = true; return SAMPLER_EXTERNAL_OES; }
+"sampler2DRect" { context->lexAfterType = true; return SAMPLER2DRECT; }
 
 "struct"       { context->lexAfterType = true; return(STRUCT); }
 
 "asm"          { return reserved_word(yyscanner); }
 
 "class"        { return reserved_word(yyscanner); }
 "union"        { return reserved_word(yyscanner); }
 "enum"         { return reserved_word(yyscanner); }
--- a/gfx/angle/src/compiler/glslang.y
+++ b/gfx/angle/src/compiler/glslang.y
@@ -93,17 +93,17 @@ extern void yyerror(TParseContext* conte
 %}
 
 %token <lex> INVARIANT HIGH_PRECISION MEDIUM_PRECISION LOW_PRECISION PRECISION
 %token <lex> ATTRIBUTE CONST_QUAL BOOL_TYPE FLOAT_TYPE INT_TYPE
 %token <lex> BREAK CONTINUE DO ELSE FOR IF DISCARD RETURN
 %token <lex> BVEC2 BVEC3 BVEC4 IVEC2 IVEC3 IVEC4 VEC2 VEC3 VEC4
 %token <lex> MATRIX2 MATRIX3 MATRIX4 IN_QUAL OUT_QUAL INOUT_QUAL UNIFORM VARYING
 %token <lex> STRUCT VOID_TYPE WHILE
-%token <lex> SAMPLER2D SAMPLERCUBE SAMPLER_EXTERNAL_OES
+%token <lex> SAMPLER2D SAMPLERCUBE SAMPLER_EXTERNAL_OES SAMPLER2DRECT
 
 %token <lex> IDENTIFIER TYPE_NAME FLOATCONSTANT INTCONSTANT BOOLCONSTANT
 %token <lex> FIELD_SELECTION
 %token <lex> LEFT_OP RIGHT_OP
 %token <lex> INC_OP DEC_OP LE_OP GE_OP EQ_OP NE_OP
 %token <lex> AND_OP OR_OP XOR_OP MUL_ASSIGN DIV_ASSIGN ADD_ASSIGN
 %token <lex> MOD_ASSIGN LEFT_ASSIGN RIGHT_ASSIGN AND_ASSIGN XOR_ASSIGN OR_ASSIGN
 %token <lex> SUB_ASSIGN
@@ -1619,16 +1619,25 @@ type_specifier_nonarray
         if (!context->supportsExtension("GL_OES_EGL_image_external")) {
             context->error($1.line, "unsupported type", "samplerExternalOES", "");
             context->recover();
         }
         FRAG_VERT_ONLY("samplerExternalOES", $1.line);
         TQualifier qual = context->symbolTable.atGlobalLevel() ? EvqGlobal : EvqTemporary;
         $$.setBasic(EbtSamplerExternalOES, qual, $1.line);
     }
+    | SAMPLER2DRECT {
+        if (!context->supportsExtension("GL_ARB_texture_rectangle")) {
+            context->error($1.line, "unsupported type", "sampler2DRect", "");
+            context->recover();
+        }
+        FRAG_VERT_ONLY("sampler2DRect", $1.line);
+        TQualifier qual = context->symbolTable.atGlobalLevel() ? EvqGlobal : EvqTemporary;
+        $$.setBasic(EbtSampler2DRect, qual, $1.line);
+    }
     | struct_specifier {
         FRAG_VERT_ONLY("struct", $1.line);
         $$ = $1;
         $$.qualifier = context->symbolTable.atGlobalLevel() ? EvqGlobal : EvqTemporary;
     }
     | TYPE_NAME {
         //
         // This is for user defined type names.  The lexical phase looked up the
--- a/gfx/angle/src/compiler/glslang_lex.cpp
+++ b/gfx/angle/src/compiler/glslang_lex.cpp
@@ -58,17 +58,16 @@ typedef int32_t flex_int32_t;
 typedef uint32_t flex_uint32_t;
 #else
 typedef signed char flex_int8_t;
 typedef short int flex_int16_t;
 typedef int flex_int32_t;
 typedef unsigned char flex_uint8_t; 
 typedef unsigned short int flex_uint16_t;
 typedef unsigned int flex_uint32_t;
-#endif /* ! C99 */
 
 /* Limits of integral types. */
 #ifndef INT8_MIN
 #define INT8_MIN               (-128)
 #endif
 #ifndef INT16_MIN
 #define INT16_MIN              (-32767-1)
 #endif
@@ -89,16 +88,18 @@ typedef unsigned int flex_uint32_t;
 #endif
 #ifndef UINT16_MAX
 #define UINT16_MAX             (65535U)
 #endif
 #ifndef UINT32_MAX
 #define UINT32_MAX             (4294967295U)
 #endif
 
+#endif /* ! C99 */
+
 #endif /* ! FLEXINT_H */
 
 #ifdef __cplusplus
 
 /* The "const" storage-class-modifier is valid. */
 #define YY_USE_CONST
 
 #else	/* ! __cplusplus */
@@ -162,17 +163,25 @@ typedef void* yyscan_t;
 
 /* Special action meaning "start processing a new file". */
 #define YY_NEW_FILE yyrestart(yyin ,yyscanner )
 
 #define YY_END_OF_BUFFER_CHAR 0
 
 /* Size of default input buffer. */
 #ifndef YY_BUF_SIZE
+#ifdef __ia64__
+/* On IA-64, the buffer size is 16k, not 8k.
+ * Moreover, YY_BUF_SIZE is 2*YY_READ_BUF_SIZE in the general case.
+ * Ditto for the __ia64__ case accordingly.
+ */
+#define YY_BUF_SIZE 32768
+#else
 #define YY_BUF_SIZE 16384
+#endif /* __ia64__ */
 #endif
 
 /* The state buf must be large enough to hold one state per character in the main buffer.
  */
 #define YY_STATE_BUF_SIZE   ((YY_BUF_SIZE + 2) * sizeof(yy_state_type))
 
 #ifndef YY_TYPEDEF_YY_BUFFER_STATE
 #define YY_TYPEDEF_YY_BUFFER_STATE
@@ -366,390 +375,394 @@ static void yy_fatal_error (yyconst char
  */
 #define YY_DO_BEFORE_ACTION \
 	yyg->yytext_ptr = yy_bp; \
 	yyleng = (size_t) (yy_cp - yy_bp); \
 	yyg->yy_hold_char = *yy_cp; \
 	*yy_cp = '\0'; \
 	yyg->yy_c_buf_p = yy_cp;
 
-#define YY_NUM_RULES 146
-#define YY_END_OF_BUFFER 147
+#define YY_NUM_RULES 147
+#define YY_END_OF_BUFFER 148
 /* This struct is not used in this scanner,
    but its presence is necessary. */
 struct yy_trans_info
 	{
 	flex_int32_t yy_verify;
 	flex_int32_t yy_nxt;
 	};
-static yyconst flex_int16_t yy_accept[422] =
+static yyconst flex_int16_t yy_accept[426] =
     {   0,
-        0,    0,    0,    0,    0,    0,  147,  145,  144,  144,
-      129,  135,  140,  124,  125,  133,  132,  121,  130,  128,
-      134,   93,   93,  122,  118,  136,  123,  137,  141,   89,
-      126,  127,  139,   89,   89,   89,   89,   89,   89,   89,
-       89,   89,   89,   89,   89,   89,   89,   89,   89,   89,
-       89,   89,   89,  119,  138,  120,  131,    3,    4,    3,
-      143,  146,  142,  115,  101,  120,  109,  104,   99,  107,
-       97,  108,   98,   96,    2,    1,  100,   95,   91,   92,
-        0,    0,   93,  127,  119,  126,  116,  112,  114,  113,
-      117,   89,  105,  111,   89,   89,   89,   89,   89,   89,
-
-       89,   89,   89,   89,   17,   89,   89,   89,   89,   89,
-       89,   89,   89,   89,   89,   89,   89,   89,   20,   22,
-       89,   89,   89,   89,   89,   89,   89,   89,   89,   89,
-       89,   89,   89,   89,   89,   89,   89,   89,   89,   89,
-       89,   89,   89,   89,   89,   89,  106,  110,    5,  142,
-        0,    1,   95,    0,    0,   94,   90,  102,  103,   49,
-       89,   89,   89,   89,   89,   89,   89,   89,   89,   89,
-       89,   89,   89,   89,   89,   89,   89,   18,   89,   89,
-       89,   89,   89,   89,   89,   89,   26,   89,   89,   89,
-       89,   89,   89,   89,   89,   23,   89,   89,   89,   89,
-
-       89,   89,   89,   89,   89,   89,   89,   89,   89,   89,
-       89,   89,   89,   89,   89,   89,   89,   89,    0,   96,
-        0,   95,   89,   28,   89,   89,   86,   89,   89,   89,
-       89,   89,   89,   89,   21,   52,   89,   89,   89,   89,
-       89,   57,   71,   89,   89,   89,   89,   89,   89,   89,
-       89,   68,    9,   33,   34,   35,   89,   89,   89,   89,
-       89,   89,   89,   89,   89,   89,   89,   89,   89,   89,
-       89,   55,   29,   89,   89,   89,   89,   89,   89,   36,
-       37,   38,   27,   89,   89,   89,   15,   42,   43,   44,
-       50,   12,   89,   89,   89,   89,   82,   83,   84,   89,
-
-       30,   72,   25,   79,   80,   81,    7,   76,   77,   78,
-       89,   24,   74,   89,   89,   39,   40,   41,   89,   89,
-       89,   89,   89,   89,   89,   89,   89,   69,   89,   89,
-       89,   89,   89,   89,   89,   51,   89,   88,   89,   89,
-       19,   89,   89,   89,   89,   70,   65,   60,   89,   89,
-       89,   89,   89,   75,   56,   89,   63,   32,   89,   85,
-       64,   48,   58,   89,   89,   89,   89,   89,   89,   89,
-       89,   59,   31,   89,   89,   89,    8,   89,   89,   89,
-       89,   89,   53,   13,   89,   14,   89,   89,   16,   66,
-       89,   89,   89,   61,   89,   89,   89,   89,   54,   73,
-
-       62,   11,   67,    6,   87,   10,   45,   89,   89,   89,
-       89,   46,   89,   89,   89,   89,   89,   89,   89,   47,
-        0
+        0,    0,    0,    0,    0,    0,  148,  146,  145,  145,
+      130,  136,  141,  125,  126,  134,  133,  122,  131,  129,
+      135,   94,   94,  123,  119,  137,  124,  138,  142,   90,
+      127,  128,  140,   90,   90,   90,   90,   90,   90,   90,
+       90,   90,   90,   90,   90,   90,   90,   90,   90,   90,
+       90,   90,   90,  120,  139,  121,  132,    3,    4,    3,
+      144,  147,  143,  116,  102,  121,  110,  105,  100,  108,
+       98,  109,   99,   97,    2,    1,  101,   96,   92,   93,
+        0,    0,   94,  128,  120,  127,  117,  113,  115,  114,
+      118,   90,  106,  112,   90,   90,   90,   90,   90,   90,
+
+       90,   90,   90,   90,   17,   90,   90,   90,   90,   90,
+       90,   90,   90,   90,   90,   90,   90,   90,   20,   22,
+       90,   90,   90,   90,   90,   90,   90,   90,   90,   90,
+       90,   90,   90,   90,   90,   90,   90,   90,   90,   90,
+       90,   90,   90,   90,   90,   90,  107,  111,    5,  143,
+        0,    1,   96,    0,    0,   95,   91,  103,  104,   50,
+       90,   90,   90,   90,   90,   90,   90,   90,   90,   90,
+       90,   90,   90,   90,   90,   90,   90,   18,   90,   90,
+       90,   90,   90,   90,   90,   90,   26,   90,   90,   90,
+       90,   90,   90,   90,   90,   23,   90,   90,   90,   90,
+
+       90,   90,   90,   90,   90,   90,   90,   90,   90,   90,
+       90,   90,   90,   90,   90,   90,   90,   90,    0,   97,
+        0,   96,   90,   28,   90,   90,   87,   90,   90,   90,
+       90,   90,   90,   90,   21,   53,   90,   90,   90,   90,
+       90,   58,   72,   90,   90,   90,   90,   90,   90,   90,
+       90,   69,    9,   33,   34,   35,   90,   90,   90,   90,
+       90,   90,   90,   90,   90,   90,   90,   90,   90,   90,
+       90,   56,   29,   90,   90,   90,   90,   90,   90,   36,
+       37,   38,   27,   90,   90,   90,   15,   42,   43,   44,
+       51,   12,   90,   90,   90,   90,   83,   84,   85,   90,
+
+       30,   73,   25,   80,   81,   82,    7,   77,   78,   79,
+       90,   24,   75,   90,   90,   39,   40,   41,   90,   90,
+       90,   90,   90,   90,   90,   90,   90,   70,   90,   90,
+       90,   90,   90,   90,   90,   52,   90,   89,   90,   90,
+       19,   90,   90,   90,   90,   71,   66,   61,   90,   90,
+       90,   90,   90,   76,   57,   90,   64,   32,   90,   86,
+       65,   49,   59,   90,   90,   90,   90,   90,   90,   90,
+       90,   60,   31,   90,   90,   90,    8,   90,   90,   90,
+       90,   90,   54,   13,   90,   14,   90,   90,   16,   67,
+       90,   90,   90,   62,   90,   90,   90,   90,   55,   74,
+
+       63,   11,   68,    6,   88,   10,   45,   90,   90,   90,
+       90,   90,   90,   46,   90,   90,   90,   48,   90,   90,
+       90,   90,   90,   47,    0
     } ;
 
 static yyconst flex_int32_t yy_ec[256] =
     {   0,
         1,    1,    1,    1,    1,    1,    1,    1,    2,    3,
         2,    2,    2,    1,    1,    1,    1,    1,    1,    1,
         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
         1,    2,    4,    1,    1,    1,    5,    6,    1,    7,
         8,    9,   10,   11,   12,   13,   14,   15,   16,   17,
        18,   19,   16,   16,   16,   20,   20,   21,   22,   23,
        24,   25,   26,    1,   27,   27,   28,   29,   30,   27,
        31,   31,   31,   31,   31,   31,   31,   31,   32,   31,
-       31,   31,   33,   31,   31,   31,   31,   34,   31,   31,
-       35,    1,   36,   37,   31,    1,   38,   39,   40,   41,
-
-       42,   43,   44,   45,   46,   31,   47,   48,   49,   50,
-       51,   52,   31,   53,   54,   55,   56,   57,   58,   59,
-       60,   61,   62,   63,   64,   65,    1,    1,    1,    1,
+       31,   33,   34,   31,   31,   31,   31,   35,   31,   31,
+       36,    1,   37,   38,   31,    1,   39,   40,   41,   42,
+
+       43,   44,   45,   46,   47,   31,   48,   49,   50,   51,
+       52,   53,   31,   54,   55,   56,   57,   58,   59,   60,
+       61,   62,   63,   64,   65,   66,    1,    1,    1,    1,
         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
 
         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
         1,    1,    1,    1,    1
     } ;
 
-static yyconst flex_int32_t yy_meta[66] =
+static yyconst flex_int32_t yy_meta[67] =
     {   0,
         1,    1,    2,    1,    1,    1,    1,    1,    1,    1,
         1,    1,    1,    1,    3,    3,    3,    3,    3,    3,
         1,    1,    1,    1,    1,    1,    3,    3,    3,    3,
-        4,    4,    4,    4,    1,    1,    1,    3,    3,    3,
-        3,    3,    3,    4,    4,    4,    4,    4,    4,    4,
+        4,    4,    4,    4,    4,    1,    1,    1,    3,    3,
+        3,    3,    3,    3,    4,    4,    4,    4,    4,    4,
         4,    4,    4,    4,    4,    4,    4,    4,    4,    4,
-        4,    1,    1,    1,    1
+        4,    4,    1,    1,    1,    1
     } ;
 
-static yyconst flex_int16_t yy_base[427] =
+static yyconst flex_int16_t yy_base[431] =
     {   0,
-        0,    0,   63,   64,   73,    0,  621,  622,  622,  622,
-      596,   44,  133,  622,  622,  595,  130,  622,  129,  127,
-      141,  153,  161,  593,  622,  177,  593,   46,  622,    0,
-      622,  622,  124,   97,  105,  137,  148,  154,  168,  565,
-      151,  167,  564,  121,  158,  558,  111,  571,  177,  176,
-      157,  188,  567,  622,  168,  622,  622,  622,  622,  597,
-      622,  622,    0,  622,  622,  622,  622,  622,  622,  622,
-      622,  622,  622,  225,  622,    0,  622,  231,  259,  267,
-      288,    0,  297,  622,  622,  622,  586,  622,  622,  622,
-      585,    0,  622,  622,  559,  552,  555,  563,  562,  549,
-
-      564,  551,  557,  545,  542,  555,  542,  539,  539,  545,
-      533,  540,  537,  547,  533,  539,  542,  543,    0,  205,
-      542,  170,  528,  541,  532,  534,  524,  538,  535,  537,
-      520,  525,  522,  511,  199,  525,  521,  523,  512,  515,
-      212,  520,  512,  524,  138,  517,  622,  622,  622,    0,
-      313,    0,  325,  341,  275,  353,    0,  622,  622,    0,
-      509,  513,  522,  519,  503,  503,  179,  518,  515,  515,
-      513,  510,  502,  508,  495,  506,  509,    0,  506,  494,
-      501,  498,  502,  495,  484,  483,  496,  499,  496,  491,
-      482,  246,  487,  490,  481,  478,  482,  488,  479,  470,
-
-      473,  471,  481,  467,  465,  465,  467,  464,  475,  474,
-      245,  469,  464,  453,  251,  471,  473,  462,  359,  365,
-      371,  377,  463,    0,  461,  301,    0,  453,  451,  459,
-      448,  465,  454,  317,    0,    0,  448,  458,  458,  443,
-      329,    0,    0,  445,  345,  446,  440,  439,  440,  439,
-      381,    0,    0,    0,    0,    0,  435,  436,  441,  432,
-      445,  440,  439,  431,  435,  427,  430,  434,  439,  438,
-      429,    0,    0,  435,  424,  424,  429,  428,  425,    0,
-        0,    0,    0,  415,  427,  429,    0,    0,    0,    0,
-        0,    0,  417,  418,  412,  422,    0,    0,    0,  413,
+        0,    0,   64,   65,   74,    0,  627,  628,  628,  628,
+      602,   45,  135,  628,  628,  601,  132,  628,  131,  129,
+      143,  155,  163,  599,  628,  179,  599,   47,  628,    0,
+      628,  628,  126,   98,  108,  147,  158,  158,  165,  570,
+      130,  107,  569,  148,  156,  563,  172,  576,  174,  181,
+      177,  195,  572,  628,  173,  628,  628,  628,  628,  603,
+      628,  628,    0,  628,  628,  628,  628,  628,  628,  628,
+      628,  628,  628,  233,  628,    0,  628,  239,  255,  271,
+      287,    0,  300,  628,  628,  628,  592,  628,  628,  628,
+      591,    0,  628,  628,  564,  557,  560,  568,  567,  554,
+
+      569,  556,  562,  550,  547,  560,  547,  544,  544,  550,
+      538,  545,  542,  552,  538,  544,  547,  548,    0,  187,
+      547,  241,  533,  546,  537,  539,  529,  543,  540,  542,
+      525,  530,  527,  516,  192,  530,  526,  528,  517,  520,
+      274,  525,  517,  529,  114,  522,  628,  628,  628,    0,
+      316,    0,  322,  338,  344,  351,    0,  628,  628,    0,
+      514,  518,  527,  524,  508,  508,  205,  523,  520,  520,
+      518,  515,  507,  513,  500,  511,  514,    0,  511,  499,
+      506,  503,  507,  500,  489,  488,  501,  504,  501,  496,
+      487,  247,  492,  495,  486,  483,  487,  493,  484,  475,
+
+      478,  476,  486,  472,  470,  470,  472,  469,  480,  479,
+      328,  474,  469,  458,  260,  476,  478,  467,  358,  366,
+      372,  378,  468,    0,  466,  276,    0,  458,  456,  464,
+      453,  470,  459,  291,    0,    0,  453,  463,  463,  448,
+      305,    0,    0,  450,  327,  451,  445,  444,  445,  444,
+      382,    0,    0,    0,    0,    0,  440,  441,  446,  437,
+      450,  445,  444,  436,  440,  432,  435,  439,  444,  443,
+      434,    0,    0,  440,  429,  429,  434,  433,  430,    0,
+        0,    0,    0,  420,  432,  434,    0,    0,    0,    0,
+        0,    0,  422,  423,  417,  427,    0,    0,    0,  418,
 
         0,    0,    0,    0,    0,    0,    0,    0,    0,    0,
-      420,    0,    0,  418,  414,    0,    0,    0,  410,  406,
-      411,  401,  414,  400,  413,  402,  409,    0,  407,  409,
-      393,  402,  408,  403,  391,    0,  393,    0,  392,  395,
-        0,  384,  383,  383,  396,    0,  398,    0,  397,  396,
-      381,  394,  381,    0,    0,  384,    0,    0,  376,    0,
-        0,    0,    0,  373,  384,  377,  383,  380,  375,  367,
-      379,    0,    0,  372,  379,  368,    0,  377,  374,  364,
-      294,  372,    0,    0,  372,    0,  368,  324,    0,    0,
-      323,  299,  310,    0,  300,  320,  282,  278,    0,    0,
-
-        0,    0,    0,    0,    0,    0,    0,  287,  266,  260,
-      257,    0,  228,  221,  221,  206,  206,  197,  160,    0,
-      622,  400,  402,  404,  408,  157
+      425,    0,    0,  423,  419,    0,    0,    0,  415,  411,
+      416,  406,  419,  405,  418,  407,  414,    0,  412,  414,
+      398,  407,  413,  408,  396,    0,  398,    0,  397,  400,
+        0,  389,  388,  388,  401,    0,  403,    0,  402,  401,
+      386,  399,  386,    0,    0,  389,    0,    0,  381,    0,
+        0,    0,    0,  378,  389,  382,  388,  385,  380,  372,
+      382,    0,    0,  365,  371,  360,    0,  369,  366,  356,
+      385,  364,    0,    0,  364,    0,  362,  361,    0,    0,
+      360,  323,  308,    0,  298,  318,  270,  265,    0,    0,
+
+        0,    0,    0,    0,    0,    0,  279,  271,  240,  240,
+      238,  237,  226,    0,  208,  188,  190,    0,  186,  173,
+      187,  164,  158,    0,  628,  415,  417,  419,  423,  186
     } ;
 
-static yyconst flex_int16_t yy_def[427] =
+static yyconst flex_int16_t yy_def[431] =
     {   0,
-      421,    1,  422,  422,  421,    5,  421,  421,  421,  421,
-      421,  421,  421,  421,  421,  421,  421,  421,  421,  421,
-      421,  421,  421,  421,  421,  421,  421,  421,  421,  423,
-      421,  421,  421,  423,  423,  423,  423,  423,  423,  423,
-      423,  423,  423,  423,  423,  423,  423,  423,  423,  423,
-      423,  423,  423,  421,  421,  421,  421,  421,  421,  421,
-      421,  421,  424,  421,  421,  421,  421,  421,  421,  421,
-      421,  421,  421,  421,  421,  425,  421,  421,  421,  421,
-      421,  426,  421,  421,  421,  421,  421,  421,  421,  421,
-      421,  423,  421,  421,  423,  423,  423,  423,  423,  423,
-
-      423,  423,  423,  423,  423,  423,  423,  423,  423,  423,
-      423,  423,  423,  423,  423,  423,  423,  423,  423,  423,
-      423,  423,  423,  423,  423,  423,  423,  423,  423,  423,
-      423,  423,  423,  423,  423,  423,  423,  423,  423,  423,
-      423,  423,  423,  423,  423,  423,  421,  421,  421,  424,
-      421,  425,  421,  421,  421,  421,  426,  421,  421,  423,
-      423,  423,  423,  423,  423,  423,  423,  423,  423,  423,
-      423,  423,  423,  423,  423,  423,  423,  423,  423,  423,
-      423,  423,  423,  423,  423,  423,  423,  423,  423,  423,
-      423,  423,  423,  423,  423,  423,  423,  423,  423,  423,
-
-      423,  423,  423,  423,  423,  423,  423,  423,  423,  423,
-      423,  423,  423,  423,  423,  423,  423,  423,  421,  421,
-      421,  421,  423,  423,  423,  423,  423,  423,  423,  423,
-      423,  423,  423,  423,  423,  423,  423,  423,  423,  423,
-      423,  423,  423,  423,  423,  423,  423,  423,  423,  423,
-      423,  423,  423,  423,  423,  423,  423,  423,  423,  423,
-      423,  423,  423,  423,  423,  423,  423,  423,  423,  423,
-      423,  423,  423,  423,  423,  423,  423,  423,  423,  423,
-      423,  423,  423,  423,  423,  423,  423,  423,  423,  423,
-      423,  423,  423,  423,  423,  423,  423,  423,  423,  423,
-
-      423,  423,  423,  423,  423,  423,  423,  423,  423,  423,
-      423,  423,  423,  423,  423,  423,  423,  423,  423,  423,
-      423,  423,  423,  423,  423,  423,  423,  423,  423,  423,
-      423,  423,  423,  423,  423,  423,  423,  423,  423,  423,
-      423,  423,  423,  423,  423,  423,  423,  423,  423,  423,
-      423,  423,  423,  423,  423,  423,  423,  423,  423,  423,
-      423,  423,  423,  423,  423,  423,  423,  423,  423,  423,
-      423,  423,  423,  423,  423,  423,  423,  423,  423,  423,
-      423,  423,  423,  423,  423,  423,  423,  423,  423,  423,
-      423,  423,  423,  423,  423,  423,  423,  423,  423,  423,
-
-      423,  423,  423,  423,  423,  423,  423,  423,  423,  423,
-      423,  423,  423,  423,  423,  423,  423,  423,  423,  423,
-        0,  421,  421,  421,  421,  421
+      425,    1,  426,  426,  425,    5,  425,  425,  425,  425,
+      425,  425,  425,  425,  425,  425,  425,  425,  425,  425,
+      425,  425,  425,  425,  425,  425,  425,  425,  425,  427,
+      425,  425,  425,  427,  427,  427,  427,  427,  427,  427,
+      427,  427,  427,  427,  427,  427,  427,  427,  427,  427,
+      427,  427,  427,  425,  425,  425,  425,  425,  425,  425,
+      425,  425,  428,  425,  425,  425,  425,  425,  425,  425,
+      425,  425,  425,  425,  425,  429,  425,  425,  425,  425,
+      425,  430,  425,  425,  425,  425,  425,  425,  425,  425,
+      425,  427,  425,  425,  427,  427,  427,  427,  427,  427,
+
+      427,  427,  427,  427,  427,  427,  427,  427,  427,  427,
+      427,  427,  427,  427,  427,  427,  427,  427,  427,  427,
+      427,  427,  427,  427,  427,  427,  427,  427,  427,  427,
+      427,  427,  427,  427,  427,  427,  427,  427,  427,  427,
+      427,  427,  427,  427,  427,  427,  425,  425,  425,  428,
+      425,  429,  425,  425,  425,  425,  430,  425,  425,  427,
+      427,  427,  427,  427,  427,  427,  427,  427,  427,  427,
+      427,  427,  427,  427,  427,  427,  427,  427,  427,  427,
+      427,  427,  427,  427,  427,  427,  427,  427,  427,  427,
+      427,  427,  427,  427,  427,  427,  427,  427,  427,  427,
+
+      427,  427,  427,  427,  427,  427,  427,  427,  427,  427,
+      427,  427,  427,  427,  427,  427,  427,  427,  425,  425,
+      425,  425,  427,  427,  427,  427,  427,  427,  427,  427,
+      427,  427,  427,  427,  427,  427,  427,  427,  427,  427,
+      427,  427,  427,  427,  427,  427,  427,  427,  427,  427,
+      427,  427,  427,  427,  427,  427,  427,  427,  427,  427,
+      427,  427,  427,  427,  427,  427,  427,  427,  427,  427,
+      427,  427,  427,  427,  427,  427,  427,  427,  427,  427,
+      427,  427,  427,  427,  427,  427,  427,  427,  427,  427,
+      427,  427,  427,  427,  427,  427,  427,  427,  427,  427,
+
+      427,  427,  427,  427,  427,  427,  427,  427,  427,  427,
+      427,  427,  427,  427,  427,  427,  427,  427,  427,  427,
+      427,  427,  427,  427,  427,  427,  427,  427,  427,  427,
+      427,  427,  427,  427,  427,  427,  427,  427,  427,  427,
+      427,  427,  427,  427,  427,  427,  427,  427,  427,  427,
+      427,  427,  427,  427,  427,  427,  427,  427,  427,  427,
+      427,  427,  427,  427,  427,  427,  427,  427,  427,  427,
+      427,  427,  427,  427,  427,  427,  427,  427,  427,  427,
+      427,  427,  427,  427,  427,  427,  427,  427,  427,  427,
+      427,  427,  427,  427,  427,  427,  427,  427,  427,  427,
+
+      427,  427,  427,  427,  427,  427,  427,  427,  427,  427,
+      427,  427,  427,  427,  427,  427,  427,  427,  427,  427,
+      427,  427,  427,  427,    0,  425,  425,  425,  425,  425
     } ;
 
-static yyconst flex_int16_t yy_nxt[688] =
+static yyconst flex_int16_t yy_nxt[695] =
     {   0,
         8,    9,   10,   11,   12,   13,   14,   15,   16,   17,
        18,   19,   20,   21,   22,   23,   23,   23,   23,   23,
        24,   25,   26,   27,   28,   29,   30,   30,   30,   30,
-       30,   30,   30,   30,   31,   32,   33,   34,   35,   36,
-       37,   38,   39,   40,   41,   42,   30,   43,   44,   45,
-       46,   47,   48,   49,   50,   51,   52,   53,   30,   30,
-       30,   54,   55,   56,   57,   59,   59,   65,   66,   90,
-       91,   60,   60,    8,   61,   62,    8,    8,    8,    8,
+       30,   30,   30,   30,   30,   31,   32,   33,   34,   35,
+       36,   37,   38,   39,   40,   41,   42,   30,   43,   44,
+       45,   46,   47,   48,   49,   50,   51,   52,   53,   30,
+       30,   30,   54,   55,   56,   57,   59,   59,   65,   66,
+       90,   91,   60,   60,    8,   61,   62,    8,    8,    8,
         8,    8,    8,    8,    8,    8,    8,    8,    8,    8,
-        8,    8,    8,    8,    8,    8,    8,    8,    8,   63,
-
-       63,   63,   63,   63,   63,   63,   63,    8,    8,    8,
-       63,   63,   63,   63,   63,   63,   63,   63,   63,   63,
+        8,    8,    8,    8,    8,    8,    8,    8,    8,    8,
+
+       63,   63,   63,   63,   63,   63,   63,   63,   63,    8,
+        8,    8,   63,   63,   63,   63,   63,   63,   63,   63,
        63,   63,   63,   63,   63,   63,   63,   63,   63,   63,
-       63,   63,   63,   63,    8,    8,    8,    8,   67,   70,
-       72,   74,   74,   74,   74,   74,   74,   93,  128,   75,
-       95,   96,   73,   71,   76,   97,   68,   98,  123,  157,
-       94,   99,  124,  129,   77,   78,  130,   79,   79,   79,
-       79,   79,   80,   78,  100,   83,   83,   83,   83,   83,
-       83,   85,   81,  216,  101,  217,   82,  102,  116,  103,
-       81,  147,  420,  104,   81,  125,  117,   86,  105,   87,
-
-       88,  107,   81,  108,  106,  110,  141,  118,  126,  119,
-      142,   82,  109,  111,  132,  112,  120,  137,  113,  190,
-      138,  133,  134,  121,  114,  143,  419,  191,  139,  144,
-      148,  135,  229,  230,  136,  140,  204,  418,  145,   74,
-       74,   74,   74,   74,   74,  153,  153,  153,  153,  153,
-      153,  205,  184,  417,  151,  185,  186,  211,  416,  187,
-      154,  188,  254,  255,  256,  212,  151,  280,  281,  282,
-      415,   78,  154,   79,   79,   79,   79,   79,   80,   78,
-      414,   80,   80,   80,   80,   80,   80,  275,   81,  156,
-      156,  156,  156,  156,  156,  276,   81,  155,  413,  155,
-
-       81,  412,  156,  156,  156,  156,  156,  156,   81,   78,
-      396,   83,   83,   83,   83,   83,   83,  288,  289,  290,
-      411,  397,  219,  398,  219,  410,   81,  220,  220,  220,
-      220,  220,  220,  297,  298,  299,  409,  408,   81,  153,
-      153,  153,  153,  153,  153,  304,  305,  306,  407,  406,
-      221,  405,  221,  404,  154,  222,  222,  222,  222,  222,
-      222,  308,  309,  310,  403,  402,  154,  156,  156,  156,
-      156,  156,  156,  220,  220,  220,  220,  220,  220,  220,
-      220,  220,  220,  220,  220,  222,  222,  222,  222,  222,
-      222,  222,  222,  222,  222,  222,  222,  316,  317,  318,
-
-       58,   58,   58,   58,   92,   92,  150,  150,  152,  401,
-      152,  152,  400,  399,  395,  394,  393,  392,  391,  390,
-      389,  388,  387,  386,  385,  384,  383,  382,  381,  380,
-      379,  378,  377,  376,  375,  374,  373,  372,  371,  370,
-      369,  368,  367,  366,  365,  364,  363,  362,  361,  360,
-      359,  358,  357,  356,  355,  354,  353,  352,  351,  350,
-      349,  348,  347,  346,  345,  344,  343,  342,  341,  340,
-      339,  338,  337,  336,  335,  334,  333,  332,  331,  330,
-      329,  328,  327,  326,  325,  324,  323,  322,  321,  320,
-      319,  315,  314,  313,  312,  311,  307,  303,  302,  301,
-
-      300,  296,  295,  294,  293,  292,  291,  287,  286,  285,
-      284,  283,  279,  278,  277,  274,  273,  272,  271,  270,
-      269,  268,  267,  266,  265,  264,  263,  262,  261,  260,
-      259,  258,  257,  253,  252,  251,  250,  249,  248,  247,
-      246,  245,  244,  243,  242,  241,  240,  239,  238,  237,
-      236,  235,  234,  233,  232,  231,  228,  227,  226,  225,
-      224,  223,  218,  215,  214,  213,  210,  209,  208,  207,
-      206,  203,  202,  201,  200,  199,  198,  197,  196,  195,
-      194,  193,  192,  189,  183,  182,  181,  180,  179,  178,
-      177,  176,  175,  174,  173,  172,  171,  170,  169,  168,
-
-      167,  166,  165,  164,  163,  162,  161,  160,  159,  158,
-      149,  146,  131,  127,  122,  115,   89,   84,   69,   64,
-      421,    7,  421,  421,  421,  421,  421,  421,  421,  421,
-      421,  421,  421,  421,  421,  421,  421,  421,  421,  421,
-      421,  421,  421,  421,  421,  421,  421,  421,  421,  421,
-      421,  421,  421,  421,  421,  421,  421,  421,  421,  421,
-      421,  421,  421,  421,  421,  421,  421,  421,  421,  421,
-      421,  421,  421,  421,  421,  421,  421,  421,  421,  421,
-      421,  421,  421,  421,  421,  421,  421
+       63,   63,   63,   63,   63,   63,    8,    8,    8,    8,
+       67,   70,   72,   74,   74,   74,   74,   74,   74,   93,
+      119,   75,   95,   96,   73,   71,   76,  120,   68,   97,
+      216,   98,  217,   94,  121,   99,   77,   78,  116,   79,
+       79,   79,   79,   79,   80,   78,  117,   83,   83,   83,
+       83,   83,   83,   85,   81,  100,  123,  118,  157,   82,
+      124,  424,   81,  423,  125,  101,  147,   81,  102,   86,
+
+      103,   87,   88,  110,  104,   81,  107,  126,  108,  105,
+      128,  111,  132,  112,   82,  106,  113,  109,  422,  133,
+      134,  421,  114,  137,  420,  129,  138,  141,  130,  135,
+      204,  142,  136,  143,  139,  184,  148,  144,  185,  186,
+      419,  140,  187,  418,  188,  205,  145,   74,   74,   74,
+       74,   74,   74,  153,  153,  153,  153,  153,  153,  229,
+      230,  417,  151,  254,  255,  256,  416,   78,  154,   79,
+       79,   79,   79,   79,   80,  151,  280,  281,  282,  415,
+      414,  154,  413,   78,   81,   80,   80,   80,   80,   80,
+       80,  190,  288,  289,  290,  412,  155,   81,  155,  191,
+
+       81,  156,  156,  156,  156,  156,  156,  297,  298,  299,
+      411,  410,   78,   81,   83,   83,   83,   83,   83,   83,
+      211,  304,  305,  306,  409,  219,  408,  219,  212,   81,
+      220,  220,  220,  220,  220,  220,  153,  153,  153,  153,
+      153,  153,   81,  308,  309,  310,  407,  221,  406,  221,
+      405,  154,  222,  222,  222,  222,  222,  222,  156,  156,
+      156,  156,  156,  156,  154,  156,  156,  156,  156,  156,
+      156,  275,  220,  220,  220,  220,  220,  220,  404,  276,
+      220,  220,  220,  220,  220,  220,  222,  222,  222,  222,
+      222,  222,  222,  222,  222,  222,  222,  222,  316,  317,
+
+      318,  396,  403,  402,  401,  400,  399,  395,  394,  393,
+      392,  391,  397,  390,  398,   58,   58,   58,   58,   92,
+       92,  150,  150,  152,  389,  152,  152,  388,  387,  386,
+      385,  384,  383,  382,  381,  380,  379,  378,  377,  376,
+      375,  374,  373,  372,  371,  370,  369,  368,  367,  366,
+      365,  364,  363,  362,  361,  360,  359,  358,  357,  356,
+      355,  354,  353,  352,  351,  350,  349,  348,  347,  346,
+      345,  344,  343,  342,  341,  340,  339,  338,  337,  336,
+      335,  334,  333,  332,  331,  330,  329,  328,  327,  326,
+      325,  324,  323,  322,  321,  320,  319,  315,  314,  313,
+
+      312,  311,  307,  303,  302,  301,  300,  296,  295,  294,
+      293,  292,  291,  287,  286,  285,  284,  283,  279,  278,
+      277,  274,  273,  272,  271,  270,  269,  268,  267,  266,
+      265,  264,  263,  262,  261,  260,  259,  258,  257,  253,
+      252,  251,  250,  249,  248,  247,  246,  245,  244,  243,
+      242,  241,  240,  239,  238,  237,  236,  235,  234,  233,
+      232,  231,  228,  227,  226,  225,  224,  223,  218,  215,
+      214,  213,  210,  209,  208,  207,  206,  203,  202,  201,
+      200,  199,  198,  197,  196,  195,  194,  193,  192,  189,
+      183,  182,  181,  180,  179,  178,  177,  176,  175,  174,
+
+      173,  172,  171,  170,  169,  168,  167,  166,  165,  164,
+      163,  162,  161,  160,  159,  158,  149,  146,  131,  127,
+      122,  115,   89,   84,   69,   64,  425,    7,  425,  425,
+      425,  425,  425,  425,  425,  425,  425,  425,  425,  425,
+      425,  425,  425,  425,  425,  425,  425,  425,  425,  425,
+      425,  425,  425,  425,  425,  425,  425,  425,  425,  425,
+      425,  425,  425,  425,  425,  425,  425,  425,  425,  425,
+      425,  425,  425,  425,  425,  425,  425,  425,  425,  425,
+      425,  425,  425,  425,  425,  425,  425,  425,  425,  425,
+      425,  425,  425,  425
+
     } ;
 
-static yyconst flex_int16_t yy_chk[688] =
+static yyconst flex_int16_t yy_chk[695] =
     {   0,
         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
-        1,    1,    1,    1,    1,    3,    4,   12,   12,   28,
-       28,    3,    4,    5,    5,    5,    5,    5,    5,    5,
+        1,    1,    1,    1,    1,    1,    3,    4,   12,   12,
+       28,   28,    3,    4,    5,    5,    5,    5,    5,    5,
         5,    5,    5,    5,    5,    5,    5,    5,    5,    5,
         5,    5,    5,    5,    5,    5,    5,    5,    5,    5,
 
         5,    5,    5,    5,    5,    5,    5,    5,    5,    5,
         5,    5,    5,    5,    5,    5,    5,    5,    5,    5,
         5,    5,    5,    5,    5,    5,    5,    5,    5,    5,
-        5,    5,    5,    5,    5,    5,    5,    5,   13,   17,
-       19,   20,   20,   20,   20,   20,   20,   33,   47,   21,
-       34,   34,   19,   17,   21,   35,   13,   35,   44,  426,
-       33,   35,   44,   47,   21,   22,   47,   22,   22,   22,
-       22,   22,   22,   23,   36,   23,   23,   23,   23,   23,
-       23,   26,   22,  145,   36,  145,   22,   36,   41,   37,
-       23,   55,  419,   37,   22,   45,   41,   26,   37,   26,
-
-       26,   38,   23,   38,   37,   39,   51,   41,   45,   42,
-       51,   22,   38,   39,   49,   39,   42,   50,   39,  122,
-       50,   49,   49,   42,   39,   52,  418,  122,   50,   52,
-       55,   49,  167,  167,   49,   50,  135,  417,   52,   74,
-       74,   74,   74,   74,   74,   78,   78,   78,   78,   78,
-       78,  135,  120,  416,   74,  120,  120,  141,  415,  120,
-       78,  120,  192,  192,  192,  141,   74,  215,  215,  215,
-      414,   79,   78,   79,   79,   79,   79,   79,   79,   80,
-      413,   80,   80,   80,   80,   80,   80,  211,   79,  155,
-      155,  155,  155,  155,  155,  211,   80,   81,  411,   81,
-
-       79,  410,   81,   81,   81,   81,   81,   81,   80,   83,
-      381,   83,   83,   83,   83,   83,   83,  226,  226,  226,
-      409,  381,  151,  381,  151,  408,   83,  151,  151,  151,
-      151,  151,  151,  234,  234,  234,  398,  397,   83,  153,
-      153,  153,  153,  153,  153,  241,  241,  241,  396,  395,
-      154,  393,  154,  392,  153,  154,  154,  154,  154,  154,
-      154,  245,  245,  245,  391,  388,  153,  156,  156,  156,
-      156,  156,  156,  219,  219,  219,  219,  219,  219,  220,
-      220,  220,  220,  220,  220,  221,  221,  221,  221,  221,
-      221,  222,  222,  222,  222,  222,  222,  251,  251,  251,
-
-      422,  422,  422,  422,  423,  423,  424,  424,  425,  387,
-      425,  425,  385,  382,  380,  379,  378,  376,  375,  374,
-      371,  370,  369,  368,  367,  366,  365,  364,  359,  356,
-      353,  352,  351,  350,  349,  347,  345,  344,  343,  342,
-      340,  339,  337,  335,  334,  333,  332,  331,  330,  329,
-      327,  326,  325,  324,  323,  322,  321,  320,  319,  315,
-      314,  311,  300,  296,  295,  294,  293,  286,  285,  284,
-      279,  278,  277,  276,  275,  274,  271,  270,  269,  268,
-      267,  266,  265,  264,  263,  262,  261,  260,  259,  258,
-      257,  250,  249,  248,  247,  246,  244,  240,  239,  238,
-
-      237,  233,  232,  231,  230,  229,  228,  225,  223,  218,
-      217,  216,  214,  213,  212,  210,  209,  208,  207,  206,
-      205,  204,  203,  202,  201,  200,  199,  198,  197,  196,
-      195,  194,  193,  191,  190,  189,  188,  187,  186,  185,
-      184,  183,  182,  181,  180,  179,  177,  176,  175,  174,
-      173,  172,  171,  170,  169,  168,  166,  165,  164,  163,
-      162,  161,  146,  144,  143,  142,  140,  139,  138,  137,
-      136,  134,  133,  132,  131,  130,  129,  128,  127,  126,
-      125,  124,  123,  121,  118,  117,  116,  115,  114,  113,
-      112,  111,  110,  109,  108,  107,  106,  105,  104,  103,
-
-      102,  101,  100,   99,   98,   97,   96,   95,   91,   87,
-       60,   53,   48,   46,   43,   40,   27,   24,   16,   11,
-        7,  421,  421,  421,  421,  421,  421,  421,  421,  421,
-      421,  421,  421,  421,  421,  421,  421,  421,  421,  421,
-      421,  421,  421,  421,  421,  421,  421,  421,  421,  421,
-      421,  421,  421,  421,  421,  421,  421,  421,  421,  421,
-      421,  421,  421,  421,  421,  421,  421,  421,  421,  421,
-      421,  421,  421,  421,  421,  421,  421,  421,  421,  421,
-      421,  421,  421,  421,  421,  421,  421
+        5,    5,    5,    5,    5,    5,    5,    5,    5,    5,
+       13,   17,   19,   20,   20,   20,   20,   20,   20,   33,
+       42,   21,   34,   34,   19,   17,   21,   42,   13,   35,
+      145,   35,  145,   33,   42,   35,   21,   22,   41,   22,
+       22,   22,   22,   22,   22,   23,   41,   23,   23,   23,
+       23,   23,   23,   26,   22,   36,   44,   41,  430,   22,
+       44,  423,   23,  422,   45,   36,   55,   22,   36,   26,
+
+       37,   26,   26,   39,   37,   23,   38,   45,   38,   37,
+       47,   39,   49,   39,   22,   37,   39,   38,  421,   49,
+       49,  420,   39,   50,  419,   47,   50,   51,   47,   49,
+      135,   51,   49,   52,   50,  120,   55,   52,  120,  120,
+      417,   50,  120,  416,  120,  135,   52,   74,   74,   74,
+       74,   74,   74,   78,   78,   78,   78,   78,   78,  167,
+      167,  415,   74,  192,  192,  192,  413,   79,   78,   79,
+       79,   79,   79,   79,   79,   74,  215,  215,  215,  412,
+      411,   78,  410,   80,   79,   80,   80,   80,   80,   80,
+       80,  122,  226,  226,  226,  409,   81,   79,   81,  122,
+
+       80,   81,   81,   81,   81,   81,   81,  234,  234,  234,
+      408,  407,   83,   80,   83,   83,   83,   83,   83,   83,
+      141,  241,  241,  241,  398,  151,  397,  151,  141,   83,
+      151,  151,  151,  151,  151,  151,  153,  153,  153,  153,
+      153,  153,   83,  245,  245,  245,  396,  154,  395,  154,
+      393,  153,  154,  154,  154,  154,  154,  154,  155,  155,
+      155,  155,  155,  155,  153,  156,  156,  156,  156,  156,
+      156,  211,  219,  219,  219,  219,  219,  219,  392,  211,
+      220,  220,  220,  220,  220,  220,  221,  221,  221,  221,
+      221,  221,  222,  222,  222,  222,  222,  222,  251,  251,
+
+      251,  381,  391,  388,  387,  385,  382,  380,  379,  378,
+      376,  375,  381,  374,  381,  426,  426,  426,  426,  427,
+      427,  428,  428,  429,  371,  429,  429,  370,  369,  368,
+      367,  366,  365,  364,  359,  356,  353,  352,  351,  350,
+      349,  347,  345,  344,  343,  342,  340,  339,  337,  335,
+      334,  333,  332,  331,  330,  329,  327,  326,  325,  324,
+      323,  322,  321,  320,  319,  315,  314,  311,  300,  296,
+      295,  294,  293,  286,  285,  284,  279,  278,  277,  276,
+      275,  274,  271,  270,  269,  268,  267,  266,  265,  264,
+      263,  262,  261,  260,  259,  258,  257,  250,  249,  248,
+
+      247,  246,  244,  240,  239,  238,  237,  233,  232,  231,
+      230,  229,  228,  225,  223,  218,  217,  216,  214,  213,
+      212,  210,  209,  208,  207,  206,  205,  204,  203,  202,
+      201,  200,  199,  198,  197,  196,  195,  194,  193,  191,
+      190,  189,  188,  187,  186,  185,  184,  183,  182,  181,
+      180,  179,  177,  176,  175,  174,  173,  172,  171,  170,
+      169,  168,  166,  165,  164,  163,  162,  161,  146,  144,
+      143,  142,  140,  139,  138,  137,  136,  134,  133,  132,
+      131,  130,  129,  128,  127,  126,  125,  124,  123,  121,
+      118,  117,  116,  115,  114,  113,  112,  111,  110,  109,
+
+      108,  107,  106,  105,  104,  103,  102,  101,  100,   99,
+       98,   97,   96,   95,   91,   87,   60,   53,   48,   46,
+       43,   40,   27,   24,   16,   11,    7,  425,  425,  425,
+      425,  425,  425,  425,  425,  425,  425,  425,  425,  425,
+      425,  425,  425,  425,  425,  425,  425,  425,  425,  425,
+      425,  425,  425,  425,  425,  425,  425,  425,  425,  425,
+      425,  425,  425,  425,  425,  425,  425,  425,  425,  425,
+      425,  425,  425,  425,  425,  425,  425,  425,  425,  425,
+      425,  425,  425,  425,  425,  425,  425,  425,  425,  425,
+      425,  425,  425,  425
+
     } ;
 
 /* Table of booleans, true if rule could match eol. */
-static yyconst flex_int32_t yy_rule_can_match_eol[147] =
+static yyconst flex_int32_t yy_rule_can_match_eol[148] =
     {   0,
 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 
     0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 
     0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 
     0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 
     0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 
     0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 
     0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 
-    0, 0, 0, 0, 1, 0, 0,     };
+    0, 0, 0, 0, 0, 1, 0, 0,     };
 
 /* The intent behind this definition is that it'll catch
  * any uses of REJECT which flex missed.
  */
 #define REJECT reject_used_but_not_detected
 #define yymore() yymore_used_but_not_detected
 #define YY_MORE_ADJ 0
 #define YY_RESTORE_YY_MORE_OFFSET
@@ -904,36 +917,41 @@ static int input (yyscan_t yyscanner );
     static void yy_push_state (int new_state ,yyscan_t yyscanner);
     
     static void yy_pop_state (yyscan_t yyscanner );
     
     static int yy_top_state (yyscan_t yyscanner );
     
 /* Amount of stuff to slurp up with each read. */
 #ifndef YY_READ_BUF_SIZE
+#ifdef __ia64__
+/* On IA-64, the buffer size is 16k, not 8k */
+#define YY_READ_BUF_SIZE 16384
+#else
 #define YY_READ_BUF_SIZE 8192
+#endif /* __ia64__ */
 #endif
 
 /* Copy whatever the last rule matched to the standard output. */
 #ifndef ECHO
 /* This used to be an fputs(), but since the string might contain NUL's,
  * we now use fwrite().
  */
-#define ECHO fwrite( yytext, yyleng, 1, yyout )
+#define ECHO do { if (fwrite( yytext, yyleng, 1, yyout )) {} } while (0)
 #endif
 
 /* Gets input and stuffs it into "buf".  number of characters read, or YY_NULL,
  * is returned in "result".
  */
 #ifndef YY_INPUT
 #define YY_INPUT(buf,result,max_size) \
 	if ( YY_CURRENT_BUFFER_LVALUE->yy_is_interactive ) \
 		{ \
 		int c = '*'; \
-		int n; \
+		size_t n; \
 		for ( n = 0; n < max_size && \
 			     (c = getc( yyin )) != EOF && c != '\n'; ++n ) \
 			buf[n] = (char) c; \
 		if ( c == '\n' ) \
 			buf[n++] = (char) c; \
 		if ( c == EOF && ferror( yyin ) ) \
 			YY_FATAL_ERROR( "input in flex scanner failed" ); \
 		result = n; \
@@ -1065,23 +1083,23 @@ yy_match:
 			if ( yy_accept[yy_current_state] )
 				{
 				yyg->yy_last_accepting_state = yy_current_state;
 				yyg->yy_last_accepting_cpos = yy_cp;
 				}
 			while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
 				{
 				yy_current_state = (int) yy_def[yy_current_state];
-				if ( yy_current_state >= 422 )
+				if ( yy_current_state >= 426 )
 					yy_c = yy_meta[(unsigned int) yy_c];
 				}
 			yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
 			++yy_cp;
 			}
-		while ( yy_current_state != 421 );
+		while ( yy_current_state != 425 );
 		yy_cp = yyg->yy_last_accepting_cpos;
 		yy_current_state = yyg->yy_last_accepting_state;
 
 yy_find_action:
 		yy_act = yy_accept[yy_current_state];
 
 		YY_DO_BEFORE_ACTION;
 
@@ -1292,21 +1310,21 @@ YY_RULE_SETUP
 { context->lexAfterType = true; return SAMPLERCUBE; }
 	YY_BREAK
 case 47:
 YY_RULE_SETUP
 { context->lexAfterType = true; return SAMPLER_EXTERNAL_OES; }
 	YY_BREAK
 case 48:
 YY_RULE_SETUP
-{ context->lexAfterType = true; return(STRUCT); }
+{ context->lexAfterType = true; return SAMPLER2DRECT; }
 	YY_BREAK
 case 49:
 YY_RULE_SETUP
-{ return reserved_word(yyscanner); }
+{ context->lexAfterType = true; return(STRUCT); }
 	YY_BREAK
 case 50:
 YY_RULE_SETUP
 { return reserved_word(yyscanner); }
 	YY_BREAK
 case 51:
 YY_RULE_SETUP
 { return reserved_word(yyscanner); }
@@ -1456,256 +1474,260 @@ YY_RULE_SETUP
 { return reserved_word(yyscanner); }
 	YY_BREAK
 case 88:
 YY_RULE_SETUP
 { return reserved_word(yyscanner); }
 	YY_BREAK
 case 89:
 YY_RULE_SETUP
+{ return reserved_word(yyscanner); }
+	YY_BREAK
+case 90:
+YY_RULE_SETUP
 {
    yylval->lex.string = NewPoolTString(yytext); 
    return check_type(yyscanner);
 }
 	YY_BREAK
-case 90:
-YY_RULE_SETUP
-{ yylval->lex.i = strtol(yytext, 0, 0); return(INTCONSTANT); }
-	YY_BREAK
 case 91:
 YY_RULE_SETUP
 { yylval->lex.i = strtol(yytext, 0, 0); return(INTCONSTANT); }
 	YY_BREAK
 case 92:
 YY_RULE_SETUP
-{ context->error(yylineno, "Invalid Octal number.", yytext, "", ""); context->recover(); return 0;}
+{ yylval->lex.i = strtol(yytext, 0, 0); return(INTCONSTANT); }
 	YY_BREAK
 case 93:
 YY_RULE_SETUP
-{ yylval->lex.i = strtol(yytext, 0, 0); return(INTCONSTANT); }
+{ context->error(yylineno, "Invalid Octal number.", yytext, "", ""); context->recover(); return 0;}
 	YY_BREAK
 case 94:
 YY_RULE_SETUP
-{ yylval->lex.f = static_cast<float>(atof_dot(yytext)); return(FLOATCONSTANT); }
+{ yylval->lex.i = strtol(yytext, 0, 0); return(INTCONSTANT); }
 	YY_BREAK
 case 95:
 YY_RULE_SETUP
 { yylval->lex.f = static_cast<float>(atof_dot(yytext)); return(FLOATCONSTANT); }
 	YY_BREAK
 case 96:
 YY_RULE_SETUP
 { yylval->lex.f = static_cast<float>(atof_dot(yytext)); return(FLOATCONSTANT); }
 	YY_BREAK
 case 97:
 YY_RULE_SETUP
-{  return(ADD_ASSIGN); }
+{ yylval->lex.f = static_cast<float>(atof_dot(yytext)); return(FLOATCONSTANT); }
 	YY_BREAK
 case 98:
 YY_RULE_SETUP
-{  return(SUB_ASSIGN); }
+{  return(ADD_ASSIGN); }
 	YY_BREAK
 case 99:
 YY_RULE_SETUP
-{  return(MUL_ASSIGN); }
+{  return(SUB_ASSIGN); }
 	YY_BREAK
 case 100:
 YY_RULE_SETUP
-{  return(DIV_ASSIGN); }
+{  return(MUL_ASSIGN); }
 	YY_BREAK
 case 101:
 YY_RULE_SETUP
-{  return(MOD_ASSIGN); }
+{  return(DIV_ASSIGN); }
 	YY_BREAK
 case 102:
 YY_RULE_SETUP
-{  return(LEFT_ASSIGN); }
+{  return(MOD_ASSIGN); }
 	YY_BREAK
 case 103:
 YY_RULE_SETUP
+{  return(LEFT_ASSIGN); }
+	YY_BREAK
+case 104:
+YY_RULE_SETUP
 {  return(RIGHT_ASSIGN); }
 	YY_BREAK
-case 104:
+case 105:
 YY_RULE_SETUP
 {  return(AND_ASSIGN); }
 	YY_BREAK
-case 105:
+case 106:
 YY_RULE_SETUP
 {  return(XOR_ASSIGN); }
 	YY_BREAK
-case 106:
+case 107:
 YY_RULE_SETUP
 {  return(OR_ASSIGN); }
 	YY_BREAK
-case 107:
-YY_RULE_SETUP
-{  return(INC_OP); }
-	YY_BREAK
 case 108:
 YY_RULE_SETUP
-{  return(DEC_OP); }
+{  return(INC_OP); }
 	YY_BREAK
 case 109:
 YY_RULE_SETUP
+{  return(DEC_OP); }
+	YY_BREAK
+case 110:
+YY_RULE_SETUP
 {  return(AND_OP); }
 	YY_BREAK
-case 110:
+case 111:
 YY_RULE_SETUP
 {  return(OR_OP); }
 	YY_BREAK
-case 111:
+case 112:
 YY_RULE_SETUP
 {  return(XOR_OP); }
 	YY_BREAK
-case 112:
+case 113:
 YY_RULE_SETUP
 {  return(LE_OP); }
 	YY_BREAK
-case 113:
+case 114:
 YY_RULE_SETUP
 {  return(GE_OP); }
 	YY_BREAK
-case 114:
+case 115:
 YY_RULE_SETUP
 {  return(EQ_OP); }
 	YY_BREAK
-case 115:
-YY_RULE_SETUP
-{  return(NE_OP); }
-	YY_BREAK
 case 116:
 YY_RULE_SETUP
+{  return(NE_OP); }
+	YY_BREAK
+case 117:
+YY_RULE_SETUP
 {  return(LEFT_OP); }
 	YY_BREAK
-case 117:
+case 118:
 YY_RULE_SETUP
 {  return(RIGHT_OP); }
 	YY_BREAK
-case 118:
+case 119:
 YY_RULE_SETUP
 { context->lexAfterType = false; return(SEMICOLON); }
 	YY_BREAK
-case 119:
+case 120:
 YY_RULE_SETUP
 { context->lexAfterType = false; return(LEFT_BRACE); }
 	YY_BREAK
-case 120:
+case 121:
 YY_RULE_SETUP
 { return(RIGHT_BRACE); }
 	YY_BREAK
-case 121:
+case 122:
 YY_RULE_SETUP
 { if (context->inTypeParen) context->lexAfterType = false; return(COMMA); }
 	YY_BREAK
-case 122:
+case 123:
 YY_RULE_SETUP
 { return(COLON); }
 	YY_BREAK
-case 123:
+case 124:
 YY_RULE_SETUP
 { context->lexAfterType = false; return(EQUAL); }
 	YY_BREAK
-case 124:
+case 125:
 YY_RULE_SETUP
 { context->lexAfterType = false; context->inTypeParen = true; return(LEFT_PAREN); }
 	YY_BREAK
-case 125:
+case 126:
 YY_RULE_SETUP
 { context->inTypeParen = false; return(RIGHT_PAREN); }
 	YY_BREAK
-case 126:
-YY_RULE_SETUP
-{ return(LEFT_BRACKET); }
-	YY_BREAK
 case 127:
 YY_RULE_SETUP
+{ return(LEFT_BRACKET); }
+	YY_BREAK
+case 128:
+YY_RULE_SETUP
 { return(RIGHT_BRACKET); }
 	YY_BREAK
-case 128:
+case 129:
 YY_RULE_SETUP
 { BEGIN(FIELDS);  return(DOT); }
 	YY_BREAK
-case 129:
+case 130:
 YY_RULE_SETUP
 { return(BANG); }
 	YY_BREAK
-case 130:
+case 131:
 YY_RULE_SETUP
 { return(DASH); }
 	YY_BREAK
-case 131:
+case 132:
 YY_RULE_SETUP
 { return(TILDE); }
 	YY_BREAK
-case 132:
-YY_RULE_SETUP
-{ return(PLUS); }
-	YY_BREAK
 case 133:
 YY_RULE_SETUP
-{ return(STAR); }
+{ return(PLUS); }
 	YY_BREAK
 case 134:
 YY_RULE_SETUP
-{ return(SLASH); }
+{ return(STAR); }
 	YY_BREAK
 case 135:
 YY_RULE_SETUP
-{ return(PERCENT); }
+{ return(SLASH); }
 	YY_BREAK
 case 136:
 YY_RULE_SETUP
-{ return(LEFT_ANGLE); }
+{ return(PERCENT); }
 	YY_BREAK
 case 137:
 YY_RULE_SETUP
-{ return(RIGHT_ANGLE); }
+{ return(LEFT_ANGLE); }
 	YY_BREAK
 case 138:
 YY_RULE_SETUP
-{ return(VERTICAL_BAR); }
+{ return(RIGHT_ANGLE); }
 	YY_BREAK
 case 139:
 YY_RULE_SETUP
+{ return(VERTICAL_BAR); }
+	YY_BREAK
+case 140:
+YY_RULE_SETUP
 { return(CARET); }
 	YY_BREAK
-case 140:
+case 141:
 YY_RULE_SETUP
 { return(AMPERSAND); }
 	YY_BREAK
-case 141:
+case 142:
 YY_RULE_SETUP
 { return(QUESTION); }
 	YY_BREAK
-case 142:
+case 143:
 YY_RULE_SETUP
 { 
     BEGIN(INITIAL);
     yylval->lex.string = NewPoolTString(yytext); 
     return FIELD_SELECTION;
 }
 	YY_BREAK
-case 143:
+case 144:
 YY_RULE_SETUP
 {}
 	YY_BREAK
-case 144:
-/* rule 144 can match eol */
+case 145:
+/* rule 145 can match eol */
 YY_RULE_SETUP
 {  }
 	YY_BREAK
 case YY_STATE_EOF(INITIAL):
 case YY_STATE_EOF(COMMENT):
 case YY_STATE_EOF(FIELDS):
 { context->AfterEOF = true; yyterminate(); }
 	YY_BREAK
-case 145:
+case 146:
 YY_RULE_SETUP
 { context->warning(yylineno, "Unknown char", yytext, ""); return 0; }
 	YY_BREAK
-case 146:
+case 147:
 YY_RULE_SETUP
 ECHO;
 	YY_BREAK
 
 	case YY_END_OF_BUFFER:
 		{
 		/* Amount of text matched not including the EOB char. */
 		int yy_amount_of_matched_text = (int) (yy_cp - yyg->yytext_ptr) - 1;
@@ -1991,17 +2013,17 @@ static int yy_get_next_buffer (yyscan_t 
 		if ( yy_accept[yy_current_state] )
 			{
 			yyg->yy_last_accepting_state = yy_current_state;
 			yyg->yy_last_accepting_cpos = yy_cp;
 			}
 		while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
 			{
 			yy_current_state = (int) yy_def[yy_current_state];
-			if ( yy_current_state >= 422 )
+			if ( yy_current_state >= 426 )
 				yy_c = yy_meta[(unsigned int) yy_c];
 			}
 		yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
 		}
 
 	return yy_current_state;
 }
 
@@ -2020,21 +2042,21 @@ static int yy_get_next_buffer (yyscan_t 
 	if ( yy_accept[yy_current_state] )
 		{
 		yyg->yy_last_accepting_state = yy_current_state;
 		yyg->yy_last_accepting_cpos = yy_cp;
 		}
 	while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
 		{
 		yy_current_state = (int) yy_def[yy_current_state];
-		if ( yy_current_state >= 422 )
+		if ( yy_current_state >= 426 )
 			yy_c = yy_meta[(unsigned int) yy_c];
 		}
 	yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
-	yy_is_jam = (yy_current_state == 421);
+	yy_is_jam = (yy_current_state == 425);
 
 	return yy_is_jam ? 0 : yy_current_state;
 }
 
 #ifndef YY_NO_INPUT
 #ifdef __cplusplus
     static int yyinput (yyscan_t yyscanner)
 #else
@@ -2434,18 +2456,18 @@ YY_BUFFER_STATE yy_scan_buffer  (char * 
 YY_BUFFER_STATE yy_scan_string (yyconst char * yystr , yyscan_t yyscanner)
 {
     
 	return yy_scan_bytes(yystr,strlen(yystr) ,yyscanner);
 }
 
 /** Setup the input buffer state to scan the given bytes. The next call to yylex() will
  * scan from a @e copy of @a bytes.
- * @param bytes the byte buffer to scan
- * @param len the number of bytes in the buffer pointed to by @a bytes.
+ * @param yybytes the byte buffer to scan
+ * @param _yybytes_len the number of bytes in the buffer pointed to by @a bytes.
  * @param yyscanner The scanner object.
  * @return the newly allocated buffer state object.
  */
 YY_BUFFER_STATE yy_scan_bytes  (yyconst char * yybytes, int  _yybytes_len , yyscan_t yyscanner)
 {
 	YY_BUFFER_STATE b;
 	char *buf;
 	yy_size_t n;
--- a/gfx/angle/src/compiler/glslang_tab.cpp
+++ b/gfx/angle/src/compiler/glslang_tab.cpp
@@ -1,40 +1,39 @@
-/* A Bison parser, made by GNU Bison 2.3.  */
+
+/* A Bison parser, made by GNU Bison 2.4.1.  */
 
 /* Skeleton implementation for Bison's Yacc-like parsers in C
-
-   Copyright (C) 1984, 1989, 1990, 2000, 2001, 2002, 2003, 2004, 2005, 2006
+   
+      Copyright (C) 1984, 1989, 1990, 2000, 2001, 2002, 2003, 2004, 2005, 2006
    Free Software Foundation, Inc.
-
-   This program is free software; you can redistribute it and/or modify
+   
+   This program is free software: you can redistribute it and/or modify
    it under the terms of the GNU General Public License as published by
-   the Free Software Foundation; either version 2, or (at your option)
-   any later version.
-
+   the Free Software Foundation, either version 3 of the License, or
+   (at your option) any later version.
+   
    This program is distributed in the hope that it will be useful,
    but WITHOUT ANY WARRANTY; without even the implied warranty of
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
    GNU General Public License for more details.
-
+   
    You should have received a copy of the GNU General Public License
-   along with this program; if not, write to the Free Software
-   Foundation, Inc., 51 Franklin Street, Fifth Floor,
-   Boston, MA 02110-1301, USA.  */
+   along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
 
 /* As a special exception, you may create a larger work that contains
    part or all of the Bison parser skeleton and distribute that work
    under terms of your choice, so long as that work isn't itself a
    parser generator using the skeleton or a modified version thereof
    as a parser skeleton.  Alternatively, if you modify or redistribute
    the parser skeleton itself, you may (at your option) remove this
    special exception, which will cause the skeleton and the resulting
    Bison output files to be licensed under the GNU General Public
    License without this special exception.
-
+   
    This special exception was added by the Free Software Foundation in
    version 2.2 of Bison.  */
 
 /* C LALR(1) parser skeleton written by Richard Stallman, by
    simplifying the original so-called "semantic" parser.  */
 
 /* All symbols defined below should begin with yy or YY, to avoid
    infringing on user name space.  This should be done even for local
@@ -42,29 +41,73 @@
    There are some unavoidable exceptions within include files to
    define necessary library symbols; they are noted "INFRINGES ON
    USER NAME SPACE" below.  */
 
 /* Identify Bison output.  */
 #define YYBISON 1
 
 /* Bison version.  */
-#define YYBISON_VERSION "2.3"
+#define YYBISON_VERSION "2.4.1"
 
 /* Skeleton name.  */
 #define YYSKELETON_NAME "yacc.c"
 
 /* Pure parsers.  */
 #define YYPURE 1
 
+/* Push parsers.  */
+#define YYPUSH 0
+
+/* Pull parsers.  */
+#define YYPULL 1
+
 /* Using locations.  */
 #define YYLSP_NEEDED 0
 
 
 
+/* Copy the first part of user declarations.  */
+
+
+//
+// Copyright (c) 2002-2010 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// This file is auto-generated by generate_parser.sh. DO NOT EDIT!
+
+#include "compiler/SymbolTable.h"
+#include "compiler/ParseHelper.h"
+#include "GLSLANG/ShaderLang.h"
+
+#define YYLEX_PARAM context->scanner
+
+
+
+/* Enabling traces.  */
+#ifndef YYDEBUG
+# define YYDEBUG 0
+#endif
+
+/* Enabling verbose error messages.  */
+#ifdef YYERROR_VERBOSE
+# undef YYERROR_VERBOSE
+# define YYERROR_VERBOSE 1
+#else
+# define YYERROR_VERBOSE 0
+#endif
+
+/* Enabling the token table.  */
+#ifndef YYTOKEN_TABLE
+# define YYTOKEN_TABLE 0
+#endif
+
+
 /* Tokens.  */
 #ifndef YYTOKENTYPE
 # define YYTOKENTYPE
    /* Put the tokens into the symbol table, so that GDB and other debuggers
       know about them.  */
    enum yytokentype {
      INVARIANT = 258,
      HIGH_PRECISION = 259,
@@ -102,206 +145,78 @@
      UNIFORM = 291,
      VARYING = 292,
      STRUCT = 293,
      VOID_TYPE = 294,
      WHILE = 295,
      SAMPLER2D = 296,
      SAMPLERCUBE = 297,
      SAMPLER_EXTERNAL_OES = 298,
-     IDENTIFIER = 299,
-     TYPE_NAME = 300,
-     FLOATCONSTANT = 301,
-     INTCONSTANT = 302,
-     BOOLCONSTANT = 303,
-     FIELD_SELECTION = 304,
-     LEFT_OP = 305,
-     RIGHT_OP = 306,
-     INC_OP = 307,
-     DEC_OP = 308,
-     LE_OP = 309,
-     GE_OP = 310,
-     EQ_OP = 311,
-     NE_OP = 312,
-     AND_OP = 313,
-     OR_OP = 314,
-     XOR_OP = 315,
-     MUL_ASSIGN = 316,
-     DIV_ASSIGN = 317,
-     ADD_ASSIGN = 318,
-     MOD_ASSIGN = 319,
-     LEFT_ASSIGN = 320,
-     RIGHT_ASSIGN = 321,
-     AND_ASSIGN = 322,
-     XOR_ASSIGN = 323,
-     OR_ASSIGN = 324,
-     SUB_ASSIGN = 325,
-     LEFT_PAREN = 326,
-     RIGHT_PAREN = 327,
-     LEFT_BRACKET = 328,
-     RIGHT_BRACKET = 329,
-     LEFT_BRACE = 330,
-     RIGHT_BRACE = 331,
-     DOT = 332,
-     COMMA = 333,
-     COLON = 334,
-     EQUAL = 335,
-     SEMICOLON = 336,
-     BANG = 337,
-     DASH = 338,
-     TILDE = 339,
-     PLUS = 340,
-     STAR = 341,
-     SLASH = 342,
-     PERCENT = 343,
-     LEFT_ANGLE = 344,
-     RIGHT_ANGLE = 345,
-     VERTICAL_BAR = 346,
-     CARET = 347,
-     AMPERSAND = 348,
-     QUESTION = 349
+     SAMPLER2DRECT = 299,
+     IDENTIFIER = 300,
+     TYPE_NAME = 301,
+     FLOATCONSTANT = 302,
+     INTCONSTANT = 303,
+     BOOLCONSTANT = 304,
+     FIELD_SELECTION = 305,
+     LEFT_OP = 306,
+     RIGHT_OP = 307,
+     INC_OP = 308,
+     DEC_OP = 309,
+     LE_OP = 310,
+     GE_OP = 311,
+     EQ_OP = 312,
+     NE_OP = 313,
+     AND_OP = 314,
+     OR_OP = 315,
+     XOR_OP = 316,
+     MUL_ASSIGN = 317,
+     DIV_ASSIGN = 318,
+     ADD_ASSIGN = 319,
+     MOD_ASSIGN = 320,
+     LEFT_ASSIGN = 321,
+     RIGHT_ASSIGN = 322,
+     AND_ASSIGN = 323,
+     XOR_ASSIGN = 324,
+     OR_ASSIGN = 325,
+     SUB_ASSIGN = 326,
+     LEFT_PAREN = 327,
+     RIGHT_PAREN = 328,
+     LEFT_BRACKET = 329,
+     RIGHT_BRACKET = 330,
+     LEFT_BRACE = 331,
+     RIGHT_BRACE = 332,
+     DOT = 333,
+     COMMA = 334,
+     COLON = 335,
+     EQUAL = 336,
+     SEMICOLON = 337,
+     BANG = 338,
+     DASH = 339,
+     TILDE = 340,
+     PLUS = 341,
+     STAR = 342,
+     SLASH = 343,
+     PERCENT = 344,
+     LEFT_ANGLE = 345,
+     RIGHT_ANGLE = 346,
+     VERTICAL_BAR = 347,
+     CARET = 348,
+     AMPERSAND = 349,
+     QUESTION = 350
    };
 #endif
-/* Tokens.  */
-#define INVARIANT 258
-#define HIGH_PRECISION 259
-#define MEDIUM_PRECISION 260
-#define LOW_PRECISION 261
-#define PRECISION 262
-#define ATTRIBUTE 263
-#define CONST_QUAL 264
-#define BOOL_TYPE 265
-#define FLOAT_TYPE 266
-#define INT_TYPE 267
-#define BREAK 268
-#define CONTINUE 269
-#define DO 270
-#define ELSE 271
-#define FOR 272
-#define IF 273
-#define DISCARD 274
-#define RETURN 275
-#define BVEC2 276
-#define BVEC3 277
-#define BVEC4 278
-#define IVEC2 279
-#define IVEC3 280
-#define IVEC4 281
-#define VEC2 282
-#define VEC3 283
-#define VEC4 284
-#define MATRIX2 285
-#define MATRIX3 286
-#define MATRIX4 287
-#define IN_QUAL 288
-#define OUT_QUAL 289
-#define INOUT_QUAL 290
-#define UNIFORM 291
-#define VARYING 292
-#define STRUCT 293
-#define VOID_TYPE 294
-#define WHILE 295
-#define SAMPLER2D 296
-#define SAMPLERCUBE 297
-#define SAMPLER_EXTERNAL_OES 298
-#define IDENTIFIER 299
-#define TYPE_NAME 300
-#define FLOATCONSTANT 301
-#define INTCONSTANT 302
-#define BOOLCONSTANT 303
-#define FIELD_SELECTION 304
-#define LEFT_OP 305
-#define RIGHT_OP 306
-#define INC_OP 307
-#define DEC_OP 308
-#define LE_OP 309
-#define GE_OP 310
-#define EQ_OP 311
-#define NE_OP 312
-#define AND_OP 313
-#define OR_OP 314
-#define XOR_OP 315
-#define MUL_ASSIGN 316
-#define DIV_ASSIGN 317
-#define ADD_ASSIGN 318
-#define MOD_ASSIGN 319
-#define LEFT_ASSIGN 320
-#define RIGHT_ASSIGN 321
-#define AND_ASSIGN 322
-#define XOR_ASSIGN 323
-#define OR_ASSIGN 324
-#define SUB_ASSIGN 325
-#define LEFT_PAREN 326
-#define RIGHT_PAREN 327
-#define LEFT_BRACKET 328
-#define RIGHT_BRACKET 329
-#define LEFT_BRACE 330
-#define RIGHT_BRACE 331
-#define DOT 332
-#define COMMA 333
-#define COLON 334
-#define EQUAL 335
-#define SEMICOLON 336
-#define BANG 337
-#define DASH 338
-#define TILDE 339
-#define PLUS 340
-#define STAR 341
-#define SLASH 342
-#define PERCENT 343
-#define LEFT_ANGLE 344
-#define RIGHT_ANGLE 345
-#define VERTICAL_BAR 346
-#define CARET 347
-#define AMPERSAND 348
-#define QUESTION 349
-
-
-
-
-/* Copy the first part of user declarations.  */
-
-
-//
-// Copyright (c) 2002-2010 The ANGLE Project Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-//
-
-// This file is auto-generated by generate_parser.sh. DO NOT EDIT!
-
-#include "compiler/SymbolTable.h"
-#include "compiler/ParseHelper.h"
-#include "GLSLANG/ShaderLang.h"
-
-#define YYLEX_PARAM context->scanner
-
-
-/* Enabling traces.  */
-#ifndef YYDEBUG
-# define YYDEBUG 0
-#endif
-
-/* Enabling verbose error messages.  */
-#ifdef YYERROR_VERBOSE
-# undef YYERROR_VERBOSE
-# define YYERROR_VERBOSE 1
-#else
-# define YYERROR_VERBOSE 0
-#endif
-
-/* Enabling the token table.  */
-#ifndef YYTOKEN_TABLE
-# define YYTOKEN_TABLE 0
-#endif
+
+
 
 #if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED
 typedef union YYSTYPE
-
 {
+
+
     struct {
         TSourceLoc line;
         union {
             TString *string;
             float f;
             int i;
             bool b;
         };
@@ -321,27 +236,26 @@ typedef union YYSTYPE
             TPrecision precision;
             TQualifier qualifier;
             TFunction* function;
             TParameter param;
             TTypeLine typeLine;
             TTypeList* typeList;
         };
     } interm;
-}
-/* Line 193 of yacc.c.  */
-
-	YYSTYPE;
+
+
+
+} YYSTYPE;
+# define YYSTYPE_IS_TRIVIAL 1
 # define yystype YYSTYPE /* obsolescent; will be withdrawn */
 # define YYSTYPE_IS_DECLARED 1
-# define YYSTYPE_IS_TRIVIAL 1
 #endif
 
 
-
 /* Copy the second part of user declarations.  */
 
 
 extern int yylex(YYSTYPE* yylval_param, void* yyscanner);
 extern void yyerror(TParseContext* context, const char* reason);
 
 #define FRAG_VERT_ONLY(S, L) {  \
     if (context->shaderType != SH_FRAGMENT_SHADER &&  \
@@ -361,18 +275,16 @@ extern void yyerror(TParseContext* conte
 #define FRAG_ONLY(S, L) {  \
     if (context->shaderType != SH_FRAGMENT_SHADER) {  \
         context->error(L, " supported in fragment shaders only ", S, "", "");  \
         context->recover();  \
     }  \
 }
 
 
-/* Line 216 of yacc.c.  */
-
 
 #ifdef short
 # undef short
 #endif
 
 #ifdef YYTYPE_UINT8
 typedef YYTYPE_UINT8 yytype_uint8;
 #else
@@ -412,17 +324,17 @@ typedef short int yytype_int16;
 # else
 #  define YYSIZE_T unsigned int
 # endif
 #endif
 
 #define YYSIZE_MAXIMUM ((YYSIZE_T) -1)
 
 #ifndef YY_
-# if defined YYENABLE_NLS && YYENABLE_NLS
+# if YYENABLE_NLS
 #  if ENABLE_NLS
 #   include <libintl.h> /* INFRINGES ON USER NAME SPACE */
 #   define YY_(msgid) dgettext ("bison-runtime", msgid)
 #  endif
 # endif
 # ifndef YY_
 #  define YY_(msgid) msgid
 # endif
@@ -437,24 +349,24 @@ typedef short int yytype_int16;
 
 /* Identity function, used to suppress warnings about constant conditions.  */
 #ifndef lint
 # define YYID(n) (n)
 #else
 #if (defined __STDC__ || defined __C99__FUNC__ \
      || defined __cplusplus || defined _MSC_VER)
 static int
-YYID (int i)
+YYID (int yyi)
 #else
 static int
-YYID (i)
-    int i;
+YYID (yyi)
+    int yyi;
 #endif
 {
-  return i;
+  return yyi;
 }
 #endif
 
 #if ! defined yyoverflow || YYERROR_VERBOSE
 
 /* The parser invokes alloca or malloc; define the necessary symbols.  */
 
 # ifdef YYSTACK_USE_ALLOCA
@@ -525,19 +437,19 @@ void free (void *); /* INFRINGES ON USER
 
 #if (! defined yyoverflow \
      && (! defined __cplusplus \
 	 || (defined YYSTYPE_IS_TRIVIAL && YYSTYPE_IS_TRIVIAL)))
 
 /* A type that is properly aligned for any stack member.  */
 union yyalloc
 {
-  yytype_int16 yyss;
-  YYSTYPE yyvs;
-  };
+  yytype_int16 yyss_alloc;
+  YYSTYPE yyvs_alloc;
+};
 
 /* The size of the maximum gap between one aligned stack and the next.  */
 # define YYSTACK_GAP_MAXIMUM (sizeof (union yyalloc) - 1)
 
 /* The size of an array large to enough to hold all stacks, each with
    N elements.  */
 # define YYSTACK_BYTES(N) \
      ((N) * (sizeof (yytype_int16) + sizeof (YYSTYPE)) \
@@ -561,46 +473,46 @@ union yyalloc
 #  endif
 # endif
 
 /* Relocate STACK from its old location to the new one.  The
    local variables YYSIZE and YYSTACKSIZE give the old and new number of
    elements in the stack, and YYPTR gives the new location of the
    stack.  Advance YYPTR to a properly aligned location for the next
    stack.  */
-# define YYSTACK_RELOCATE(Stack)					\
+# define YYSTACK_RELOCATE(Stack_alloc, Stack)				\
     do									\
       {									\
 	YYSIZE_T yynewbytes;						\
-	YYCOPY (&yyptr->Stack, Stack, yysize);				\
-	Stack = &yyptr->Stack;						\
+	YYCOPY (&yyptr->Stack_alloc, Stack, yysize);			\
+	Stack = &yyptr->Stack_alloc;					\
 	yynewbytes = yystacksize * sizeof (*Stack) + YYSTACK_GAP_MAXIMUM; \
 	yyptr += yynewbytes / sizeof (*yyptr);				\
       }									\
     while (YYID (0))
 
 #endif
 
 /* YYFINAL -- State number of the termination state.  */
-#define YYFINAL  70
+#define YYFINAL  71
 /* YYLAST -- Last index in YYTABLE.  */
-#define YYLAST   1327
+#define YYLAST   1370
 
 /* YYNTOKENS -- Number of terminals.  */
-#define YYNTOKENS  95
+#define YYNTOKENS  96
 /* YYNNTS -- Number of nonterminals.  */
 #define YYNNTS  80
 /* YYNRULES -- Number of rules.  */
-#define YYNRULES  196
+#define YYNRULES  197
 /* YYNRULES -- Number of states.  */
-#define YYNSTATES  299
+#define YYNSTATES  300
 
 /* YYTRANSLATE(YYLEX) -- Bison symbol number corresponding to YYLEX.  */
 #define YYUNDEFTOK  2
-#define YYMAXUTOK   349
+#define YYMAXUTOK   350
 
 #define YYTRANSLATE(YYX)						\
   ((unsigned int) (YYX) <= YYMAXUTOK ? yytranslate[YYX] : YYUNDEFTOK)
 
 /* YYTRANSLATE[YYLEX] -- Bison symbol number corresponding to YYLEX.  */
 static const yytype_uint8 yytranslate[] =
 {
        0,     2,     2,     2,     2,     2,     2,     2,     2,     2,
@@ -632,17 +544,18 @@ static const yytype_uint8 yytranslate[] 
        5,     6,     7,     8,     9,    10,    11,    12,    13,    14,
       15,    16,    17,    18,    19,    20,    21,    22,    23,    24,
       25,    26,    27,    28,    29,    30,    31,    32,    33,    34,
       35,    36,    37,    38,    39,    40,    41,    42,    43,    44,
       45,    46,    47,    48,    49,    50,    51,    52,    53,    54,
       55,    56,    57,    58,    59,    60,    61,    62,    63,    64,
       65,    66,    67,    68,    69,    70,    71,    72,    73,    74,
       75,    76,    77,    78,    79,    80,    81,    82,    83,    84,
-      85,    86,    87,    88,    89,    90,    91,    92,    93,    94
+      85,    86,    87,    88,    89,    90,    91,    92,    93,    94,
+      95
 };
 
 #if YYDEBUG
 /* YYPRHS[YYN] -- Index of the first RHS symbol of rule number YYN in
    YYRHS.  */
 static const yytype_uint16 yyprhs[] =
 {
        0,     0,     3,     5,     7,     9,    11,    13,    17,    19,
@@ -653,84 +566,85 @@ static const yytype_uint16 yyprhs[] =
      140,   142,   144,   146,   148,   152,   154,   158,   160,   164,
      166,   172,   174,   178,   180,   182,   184,   186,   188,   190,
      194,   196,   199,   202,   207,   210,   212,   214,   217,   221,
      225,   228,   234,   238,   241,   245,   248,   249,   251,   253,
      255,   257,   259,   263,   269,   276,   282,   284,   287,   292,
      298,   303,   306,   308,   311,   313,   315,   317,   320,   322,
      324,   327,   329,   331,   333,   335,   340,   342,   344,   346,
      348,   350,   352,   354,   356,   358,   360,   362,   364,   366,
-     368,   370,   372,   374,   376,   378,   380,   382,   383,   390,
-     391,   397,   399,   402,   406,   408,   412,   414,   419,   421,
-     423,   425,   427,   429,   431,   433,   435,   437,   440,   441,
-     442,   448,   450,   452,   455,   459,   461,   464,   466,   469,
-     475,   479,   481,   483,   488,   489,   496,   497,   506,   507,
-     515,   517,   519,   521,   522,   525,   529,   532,   535,   538,
-     542,   545,   547,   550,   552,   554,   555
+     368,   370,   372,   374,   376,   378,   380,   382,   384,   385,
+     392,   393,   399,   401,   404,   408,   410,   414,   416,   421,
+     423,   425,   427,   429,   431,   433,   435,   437,   439,   442,
+     443,   444,   450,   452,   454,   457,   461,   463,   466,   468,
+     471,   477,   481,   483,   485,   490,   491,   498,   499,   508,
+     509,   517,   519,   521,   523,   524,   527,   531,   534,   537,
+     540,   544,   547,   549,   552,   554,   556,   557
 };
 
 /* YYRHS -- A `-1'-separated list of the rules' RHS.  */
 static const yytype_int16 yyrhs[] =
 {
-     171,     0,    -1,    44,    -1,    96,    -1,    47,    -1,    46,
-      -1,    48,    -1,    71,   123,    72,    -1,    97,    -1,    98,
-      73,    99,    74,    -1,   100,    -1,    98,    77,    49,    -1,
-      98,    52,    -1,    98,    53,    -1,   123,    -1,   101,    -1,
-     102,    -1,    98,    77,   102,    -1,   104,    72,    -1,   103,
-      72,    -1,   105,    39,    -1,   105,    -1,   105,   121,    -1,
-     104,    78,   121,    -1,   106,    71,    -1,   141,    -1,    44,
-      -1,    49,    -1,    98,    -1,    52,   107,    -1,    53,   107,
-      -1,   108,   107,    -1,    85,    -1,    83,    -1,    82,    -1,
-     107,    -1,   109,    86,   107,    -1,   109,    87,   107,    -1,
-     109,    -1,   110,    85,   109,    -1,   110,    83,   109,    -1,
-     110,    -1,   111,    -1,   112,    89,   111,    -1,   112,    90,
-     111,    -1,   112,    54,   111,    -1,   112,    55,   111,    -1,
-     112,    -1,   113,    56,   112,    -1,   113,    57,   112,    -1,
-     113,    -1,   114,    -1,   115,    -1,   116,    -1,   117,    58,
-     116,    -1,   117,    -1,   118,    60,   117,    -1,   118,    -1,
-     119,    59,   118,    -1,   119,    -1,   119,    94,   123,    79,
-     121,    -1,   120,    -1,   107,   122,   121,    -1,    80,    -1,
-      61,    -1,    62,    -1,    63,    -1,    70,    -1,   121,    -1,
-     123,    78,   121,    -1,   120,    -1,   126,    81,    -1,   134,
-      81,    -1,     7,   139,   140,    81,    -1,   127,    72,    -1,
-     129,    -1,   128,    -1,   129,   131,    -1,   128,    78,   131,
-      -1,   136,    44,    71,    -1,   138,    44,    -1,   138,    44,
-      73,   124,    74,    -1,   137,   132,   130,    -1,   132,   130,
-      -1,   137,   132,   133,    -1,   132,   133,    -1,    -1,    33,
-      -1,    34,    -1,    35,    -1,   138,    -1,   135,    -1,   134,
-      78,    44,    -1,   134,    78,    44,    73,    74,    -1,   134,
-      78,    44,    73,   124,    74,    -1,   134,    78,    44,    80,
-     149,    -1,   136,    -1,   136,    44,    -1,   136,    44,    73,
-      74,    -1,   136,    44,    73,   124,    74,    -1,   136,    44,
-      80,   149,    -1,     3,    44,    -1,   138,    -1,   137,   138,
+     172,     0,    -1,    45,    -1,    97,    -1,    48,    -1,    47,
+      -1,    49,    -1,    72,   124,    73,    -1,    98,    -1,    99,
+      74,   100,    75,    -1,   101,    -1,    99,    78,    50,    -1,
+      99,    53,    -1,    99,    54,    -1,   124,    -1,   102,    -1,
+     103,    -1,    99,    78,   103,    -1,   105,    73,    -1,   104,
+      73,    -1,   106,    39,    -1,   106,    -1,   106,   122,    -1,
+     105,    79,   122,    -1,   107,    72,    -1,   142,    -1,    45,
+      -1,    50,    -1,    99,    -1,    53,   108,    -1,    54,   108,
+      -1,   109,   108,    -1,    86,    -1,    84,    -1,    83,    -1,
+     108,    -1,   110,    87,   108,    -1,   110,    88,   108,    -1,
+     110,    -1,   111,    86,   110,    -1,   111,    84,   110,    -1,
+     111,    -1,   112,    -1,   113,    90,   112,    -1,   113,    91,
+     112,    -1,   113,    55,   112,    -1,   113,    56,   112,    -1,
+     113,    -1,   114,    57,   113,    -1,   114,    58,   113,    -1,
+     114,    -1,   115,    -1,   116,    -1,   117,    -1,   118,    59,
+     117,    -1,   118,    -1,   119,    61,   118,    -1,   119,    -1,
+     120,    60,   119,    -1,   120,    -1,   120,    95,   124,    80,
+     122,    -1,   121,    -1,   108,   123,   122,    -1,    81,    -1,
+      62,    -1,    63,    -1,    64,    -1,    71,    -1,   122,    -1,
+     124,    79,   122,    -1,   121,    -1,   127,    82,    -1,   135,
+      82,    -1,     7,   140,   141,    82,    -1,   128,    73,    -1,
+     130,    -1,   129,    -1,   130,   132,    -1,   129,    79,   132,
+      -1,   137,    45,    72,    -1,   139,    45,    -1,   139,    45,
+      74,   125,    75,    -1,   138,   133,   131,    -1,   133,   131,
+      -1,   138,   133,   134,    -1,   133,   134,    -1,    -1,    33,
+      -1,    34,    -1,    35,    -1,   139,    -1,   136,    -1,   135,
+      79,    45,    -1,   135,    79,    45,    74,    75,    -1,   135,
+      79,    45,    74,   125,    75,    -1,   135,    79,    45,    81,
+     150,    -1,   137,    -1,   137,    45,    -1,   137,    45,    74,
+      75,    -1,   137,    45,    74,   125,    75,    -1,   137,    45,
+      81,   150,    -1,     3,    45,    -1,   139,    -1,   138,   139,
       -1,     9,    -1,     8,    -1,    37,    -1,     3,    37,    -1,
-      36,    -1,   140,    -1,   139,   140,    -1,     4,    -1,     5,
-      -1,     6,    -1,   141,    -1,   141,    73,   124,    74,    -1,
+      36,    -1,   141,    -1,   140,   141,    -1,     4,    -1,     5,
+      -1,     6,    -1,   142,    -1,   142,    74,   125,    75,    -1,
       39,    -1,    11,    -1,    12,    -1,    10,    -1,    27,    -1,
       28,    -1,    29,    -1,    21,    -1,    22,    -1,    23,    -1,
       24,    -1,    25,    -1,    26,    -1,    30,    -1,    31,    -1,
-      32,    -1,    41,    -1,    42,    -1,    43,    -1,   142,    -1,
-      45,    -1,    -1,    38,    44,    75,   143,   145,    76,    -1,
-      -1,    38,    75,   144,   145,    76,    -1,   146,    -1,   145,
-     146,    -1,   138,   147,    81,    -1,   148,    -1,   147,    78,
-     148,    -1,    44,    -1,    44,    73,   124,    74,    -1,   121,
-      -1,   125,    -1,   153,    -1,   152,    -1,   150,    -1,   159,
-      -1,   160,    -1,   163,    -1,   170,    -1,    75,    76,    -1,
-      -1,    -1,    75,   154,   158,   155,    76,    -1,   157,    -1,
-     152,    -1,    75,    76,    -1,    75,   158,    76,    -1,   151,
-      -1,   158,   151,    -1,    81,    -1,   123,    81,    -1,    18,
-      71,   123,    72,   161,    -1,   151,    16,   151,    -1,   151,
-      -1,   123,    -1,   136,    44,    80,   149,    -1,    -1,    40,
-      71,   164,   162,    72,   156,    -1,    -1,    15,   165,   151,
-      40,    71,   123,    72,    81,    -1,    -1,    17,    71,   166,
-     167,   169,    72,   156,    -1,   159,    -1,   150,    -1,   162,
-      -1,    -1,   168,    81,    -1,   168,    81,   123,    -1,    14,
-      81,    -1,    13,    81,    -1,    20,    81,    -1,    20,   123,
-      81,    -1,    19,    81,    -1,   172,    -1,   171,   172,    -1,
-     173,    -1,   125,    -1,    -1,   126,   174,   157,    -1
+      32,    -1,    41,    -1,    42,    -1,    43,    -1,    44,    -1,
+     143,    -1,    46,    -1,    -1,    38,    45,    76,   144,   146,
+      77,    -1,    -1,    38,    76,   145,   146,    77,    -1,   147,
+      -1,   146,   147,    -1,   139,   148,    82,    -1,   149,    -1,
+     148,    79,   149,    -1,    45,    -1,    45,    74,   125,    75,
+      -1,   122,    -1,   126,    -1,   154,    -1,   153,    -1,   151,
+      -1,   160,    -1,   161,    -1,   164,    -1,   171,    -1,    76,
+      77,    -1,    -1,    -1,    76,   155,   159,   156,    77,    -1,
+     158,    -1,   153,    -1,    76,    77,    -1,    76,   159,    77,
+      -1,   152,    -1,   159,   152,    -1,    82,    -1,   124,    82,
+      -1,    18,    72,   124,    73,   162,    -1,   152,    16,   152,
+      -1,   152,    -1,   124,    -1,   137,    45,    81,   150,    -1,
+      -1,    40,    72,   165,   163,    73,   157,    -1,    -1,    15,
+     166,   152,    40,    72,   124,    73,    82,    -1,    -1,    17,
+      72,   167,   168,   170,    73,   157,    -1,   160,    -1,   151,
+      -1,   163,    -1,    -1,   169,    82,    -1,   169,    82,   124,
+      -1,    14,    82,    -1,    13,    82,    -1,    20,    82,    -1,
+      20,   124,    82,    -1,    19,    82,    -1,   173,    -1,   172,
+     173,    -1,   174,    -1,   126,    -1,    -1,   127,   175,   158,
+      -1
 };
 
 /* YYRLINE[YYN] -- source line where rule number YYN was defined.  */
 static const yytype_uint16 yyrline[] =
 {
        0,   153,   153,   188,   191,   204,   209,   214,   220,   223,
      296,   299,   408,   418,   431,   439,   538,   541,   549,   553,
      560,   564,   571,   577,   586,   594,   649,   656,   666,   669,
@@ -739,48 +653,48 @@ static const yytype_uint16 yyrline[] =
      831,   835,   839,   843,   844,   857,   858,   871,   872,   885,
      886,   903,   904,   917,   918,   919,   920,   921,   925,   928,
      939,   947,   972,   977,   984,  1020,  1023,  1030,  1038,  1059,
     1078,  1089,  1118,  1123,  1133,  1138,  1148,  1151,  1154,  1157,
     1163,  1170,  1173,  1189,  1207,  1231,  1254,  1258,  1276,  1284,
     1316,  1336,  1412,  1421,  1444,  1447,  1453,  1461,  1469,  1477,
     1487,  1494,  1497,  1500,  1506,  1509,  1524,  1528,  1532,  1536,
     1545,  1550,  1555,  1560,  1565,  1570,  1575,  1580,  1585,  1590,
-    1596,  1602,  1608,  1613,  1618,  1627,  1632,  1645,  1645,  1659,
-    1659,  1668,  1671,  1686,  1722,  1726,  1732,  1740,  1756,  1760,
-    1764,  1765,  1771,  1772,  1773,  1774,  1775,  1779,  1780,  1780,
-    1780,  1790,  1791,  1796,  1799,  1809,  1812,  1818,  1819,  1823,
-    1831,  1835,  1845,  1850,  1867,  1867,  1872,  1872,  1879,  1879,
-    1887,  1890,  1896,  1899,  1905,  1909,  1916,  1923,  1930,  1937,
-    1948,  1957,  1961,  1968,  1971,  1977,  1977
+    1596,  1602,  1608,  1613,  1618,  1627,  1636,  1641,  1654,  1654,
+    1668,  1668,  1677,  1680,  1695,  1731,  1735,  1741,  1749,  1765,
+    1769,  1773,  1774,  1780,  1781,  1782,  1783,  1784,  1788,  1789,
+    1789,  1789,  1799,  1800,  1805,  1808,  1818,  1821,  1827,  1828,
+    1832,  1840,  1844,  1854,  1859,  1876,  1876,  1881,  1881,  1888,
+    1888,  1896,  1899,  1905,  1908,  1914,  1918,  1925,  1932,  1939,
+    1946,  1957,  1966,  1970,  1977,  1980,  1986,  1986
 };
 #endif
 
 #if YYDEBUG || YYERROR_VERBOSE || YYTOKEN_TABLE
 /* YYTNAME[SYMBOL-NUM] -- String name of the symbol SYMBOL-NUM.
    First, the terminals, then, starting at YYNTOKENS, nonterminals.  */
 static const char *const yytname[] =
 {
   "$end", "error", "$undefined", "INVARIANT", "HIGH_PRECISION",
   "MEDIUM_PRECISION", "LOW_PRECISION", "PRECISION", "ATTRIBUTE",
   "CONST_QUAL", "BOOL_TYPE", "FLOAT_TYPE", "INT_TYPE", "BREAK", "CONTINUE",
   "DO", "ELSE", "FOR", "IF", "DISCARD", "RETURN", "BVEC2", "BVEC3",
   "BVEC4", "IVEC2", "IVEC3", "IVEC4", "VEC2", "VEC3", "VEC4", "MATRIX2",
   "MATRIX3", "MATRIX4", "IN_QUAL", "OUT_QUAL", "INOUT_QUAL", "UNIFORM",
   "VARYING", "STRUCT", "VOID_TYPE", "WHILE", "SAMPLER2D", "SAMPLERCUBE",
-  "SAMPLER_EXTERNAL_OES", "IDENTIFIER", "TYPE_NAME", "FLOATCONSTANT",
-  "INTCONSTANT", "BOOLCONSTANT", "FIELD_SELECTION", "LEFT_OP", "RIGHT_OP",
-  "INC_OP", "DEC_OP", "LE_OP", "GE_OP", "EQ_OP", "NE_OP", "AND_OP",
-  "OR_OP", "XOR_OP", "MUL_ASSIGN", "DIV_ASSIGN", "ADD_ASSIGN",
-  "MOD_ASSIGN", "LEFT_ASSIGN", "RIGHT_ASSIGN", "AND_ASSIGN", "XOR_ASSIGN",
-  "OR_ASSIGN", "SUB_ASSIGN", "LEFT_PAREN", "RIGHT_PAREN", "LEFT_BRACKET",
-  "RIGHT_BRACKET", "LEFT_BRACE", "RIGHT_BRACE", "DOT", "COMMA", "COLON",
-  "EQUAL", "SEMICOLON", "BANG", "DASH", "TILDE", "PLUS", "STAR", "SLASH",
-  "PERCENT", "LEFT_ANGLE", "RIGHT_ANGLE", "VERTICAL_BAR", "CARET",
-  "AMPERSAND", "QUESTION", "$accept", "variable_identifier",
+  "SAMPLER_EXTERNAL_OES", "SAMPLER2DRECT", "IDENTIFIER", "TYPE_NAME",
+  "FLOATCONSTANT", "INTCONSTANT", "BOOLCONSTANT", "FIELD_SELECTION",
+  "LEFT_OP", "RIGHT_OP", "INC_OP", "DEC_OP", "LE_OP", "GE_OP", "EQ_OP",
+  "NE_OP", "AND_OP", "OR_OP", "XOR_OP", "MUL_ASSIGN", "DIV_ASSIGN",
+  "ADD_ASSIGN", "MOD_ASSIGN", "LEFT_ASSIGN", "RIGHT_ASSIGN", "AND_ASSIGN",
+  "XOR_ASSIGN", "OR_ASSIGN", "SUB_ASSIGN", "LEFT_PAREN", "RIGHT_PAREN",
+  "LEFT_BRACKET", "RIGHT_BRACKET", "LEFT_BRACE", "RIGHT_BRACE", "DOT",
+  "COMMA", "COLON", "EQUAL", "SEMICOLON", "BANG", "DASH", "TILDE", "PLUS",
+  "STAR", "SLASH", "PERCENT", "LEFT_ANGLE", "RIGHT_ANGLE", "VERTICAL_BAR",
+  "CARET", "AMPERSAND", "QUESTION", "$accept", "variable_identifier",
   "primary_expression", "postfix_expression", "integer_expression",
   "function_call", "function_call_or_method", "function_call_generic",
   "function_call_header_no_parameters",
   "function_call_header_with_parameters", "function_call_header",
   "function_identifier", "unary_expression", "unary_operator",
   "multiplicative_expression", "additive_expression", "shift_expression",
   "relational_expression", "equality_expression", "and_expression",
   "exclusive_or_expression", "inclusive_or_expression",
@@ -789,26 +703,26 @@ static const char *const yytname[] =
   "assignment_expression", "assignment_operator", "expression",
   "constant_expression", "declaration", "function_prototype",
   "function_declarator", "function_header_with_parameters",
   "function_header", "parameter_declarator", "parameter_declaration",
   "parameter_qualifier", "parameter_type_specifier",
   "init_declarator_list", "single_declaration", "fully_specified_type",
   "type_qualifier", "type_specifier", "precision_qualifier",
   "type_specifier_no_prec", "type_specifier_nonarray", "struct_specifier",
-  "@1", "@2", "struct_declaration_list", "struct_declaration",
+  "$@1", "$@2", "struct_declaration_list", "struct_declaration",
   "struct_declarator_list", "struct_declarator", "initializer",
   "declaration_statement", "statement", "simple_statement",
-  "compound_statement", "@3", "@4", "statement_no_new_scope",
+  "compound_statement", "$@3", "$@4", "statement_no_new_scope",
   "compound_statement_no_new_scope", "statement_list",
   "expression_statement", "selection_statement",
-  "selection_rest_statement", "condition", "iteration_statement", "@5",
-  "@6", "@7", "for_init_statement", "conditionopt", "for_rest_statement",
+  "selection_rest_statement", "condition", "iteration_statement", "$@5",
+  "$@6", "$@7", "for_init_statement", "conditionopt", "for_rest_statement",
   "jump_statement", "translation_unit", "external_declaration",
-  "function_definition", "@8", 0
+  "function_definition", "$@8", 0
 };
 #endif
 
 # ifdef YYPRINT
 /* YYTOKNUM[YYLEX-NUM] -- Internal token number corresponding to
    token YYLEX-NUM.  */
 static const yytype_uint16 yytoknum[] =
 {
@@ -816,43 +730,43 @@ static const yytype_uint16 yytoknum[] =
      265,   266,   267,   268,   269,   270,   271,   272,   273,   274,
      275,   276,   277,   278,   279,   280,   281,   282,   283,   284,
      285,   286,   287,   288,   289,   290,   291,   292,   293,   294,
      295,   296,   297,   298,   299,   300,   301,   302,   303,   304,
      305,   306,   307,   308,   309,   310,   311,   312,   313,   314,
      315,   316,   317,   318,   319,   320,   321,   322,   323,   324,
      325,   326,   327,   328,   329,   330,   331,   332,   333,   334,
      335,   336,   337,   338,   339,   340,   341,   342,   343,   344,
-     345,   346,   347,   348,   349
+     345,   346,   347,   348,   349,   350
 };
 # endif
 
 /* YYR1[YYN] -- Symbol number of symbol that rule YYN derives.  */
 static const yytype_uint8 yyr1[] =
 {
-       0,    95,    96,    97,    97,    97,    97,    97,    98,    98,
-      98,    98,    98,    98,    99,   100,   101,   101,   102,   102,
-     103,   103,   104,   104,   105,   106,   106,   106,   107,   107,
-     107,   107,   108,   108,   108,   109,   109,   109,   110,   110,
-     110,   111,   112,   112,   112,   112,   112,   113,   113,   113,
-     114,   115,   116,   117,   117,   118,   118,   119,   119,   120,
-     120,   121,   121,   122,   122,   122,   122,   122,   123,   123,
-     124,   125,   125,   125,   126,   127,   127,   128,   128,   129,
-     130,   130,   131,   131,   131,   131,   132,   132,   132,   132,
-     133,   134,   134,   134,   134,   134,   135,   135,   135,   135,
-     135,   135,   136,   136,   137,   137,   137,   137,   137,   138,
-     138,   139,   139,   139,   140,   140,   141,   141,   141,   141,
-     141,   141,   141,   141,   141,   141,   141,   141,   141,   141,
-     141,   141,   141,   141,   141,   141,   141,   143,   142,   144,
-     142,   145,   145,   146,   147,   147,   148,   148,   149,   150,
-     151,   151,   152,   152,   152,   152,   152,   153,   154,   155,
-     153,   156,   156,   157,   157,   158,   158,   159,   159,   160,
-     161,   161,   162,   162,   164,   163,   165,   163,   166,   163,
-     167,   167,   168,   168,   169,   169,   170,   170,   170,   170,
-     170,   171,   171,   172,   172,   174,   173
+       0,    96,    97,    98,    98,    98,    98,    98,    99,    99,
+      99,    99,    99,    99,   100,   101,   102,   102,   103,   103,
+     104,   104,   105,   105,   106,   107,   107,   107,   108,   108,
+     108,   108,   109,   109,   109,   110,   110,   110,   111,   111,
+     111,   112,   113,   113,   113,   113,   113,   114,   114,   114,
+     115,   116,   117,   118,   118,   119,   119,   120,   120,   121,
+     121,   122,   122,   123,   123,   123,   123,   123,   124,   124,
+     125,   126,   126,   126,   127,   128,   128,   129,   129,   130,
+     131,   131,   132,   132,   132,   132,   133,   133,   133,   133,
+     134,   135,   135,   135,   135,   135,   136,   136,   136,   136,
+     136,   136,   137,   137,   138,   138,   138,   138,   138,   139,
+     139,   140,   140,   140,   141,   141,   142,   142,   142,   142,
+     142,   142,   142,   142,   142,   142,   142,   142,   142,   142,
+     142,   142,   142,   142,   142,   142,   142,   142,   144,   143,
+     145,   143,   146,   146,   147,   148,   148,   149,   149,   150,
+     151,   152,   152,   153,   153,   153,   153,   153,   154,   155,
+     156,   154,   157,   157,   158,   158,   159,   159,   160,   160,
+     161,   162,   162,   163,   163,   165,   164,   166,   164,   167,
+     164,   168,   168,   169,   169,   170,   170,   171,   171,   171,
+     171,   171,   172,   172,   173,   173,   175,   174
 };
 
 /* YYR2[YYN] -- Number of symbols composing right hand side of rule YYN.  */
 static const yytype_uint8 yyr2[] =
 {
        0,     2,     1,     1,     1,     1,     1,     3,     1,     4,
        1,     3,     2,     2,     1,     1,     1,     3,     2,     2,
        2,     1,     2,     3,     2,     1,     1,     1,     1,     2,
@@ -861,438 +775,448 @@ static const yytype_uint8 yyr2[] =
        1,     1,     1,     1,     3,     1,     3,     1,     3,     1,
        5,     1,     3,     1,     1,     1,     1,     1,     1,     3,
        1,     2,     2,     4,     2,     1,     1,     2,     3,     3,
        2,     5,     3,     2,     3,     2,     0,     1,     1,     1,
        1,     1,     3,     5,     6,     5,     1,     2,     4,     5,
        4,     2,     1,     2,     1,     1,     1,     2,     1,     1,
        2,     1,     1,     1,     1,     4,     1,     1,     1,     1,
        1,     1,     1,     1,     1,     1,     1,     1,     1,     1,
-       1,     1,     1,     1,     1,     1,     1,     0,     6,     0,
-       5,     1,     2,     3,     1,     3,     1,     4,     1,     1,
-       1,     1,     1,     1,     1,     1,     1,     2,     0,     0,
-       5,     1,     1,     2,     3,     1,     2,     1,     2,     5,
-       3,     1,     1,     4,     0,     6,     0,     8,     0,     7,
-       1,     1,     1,     0,     2,     3,     2,     2,     2,     3,
-       2,     1,     2,     1,     1,     0,     3
+       1,     1,     1,     1,     1,     1,     1,     1,     0,     6,
+       0,     5,     1,     2,     3,     1,     3,     1,     4,     1,
+       1,     1,     1,     1,     1,     1,     1,     1,     2,     0,
+       0,     5,     1,     1,     2,     3,     1,     2,     1,     2,
+       5,     3,     1,     1,     4,     0,     6,     0,     8,     0,
+       7,     1,     1,     1,     0,     2,     3,     2,     2,     2,
+       3,     2,     1,     2,     1,     1,     0,     3
 };
 
 /* YYDEFACT[STATE-NAME] -- Default rule to reduce with in state
    STATE-NUM when YYTABLE doesn't specify something else to do.  Zero
    means the default is an error.  */
 static const yytype_uint8 yydefact[] =
 {
        0,     0,   111,   112,   113,     0,   105,   104,   119,   117,
      118,   123,   124,   125,   126,   127,   128,   120,   121,   122,
      129,   130,   131,   108,   106,     0,   116,   132,   133,   134,
-     136,   194,   195,     0,    76,    86,     0,    91,    96,     0,
-     102,     0,   109,   114,   135,     0,   191,   193,   107,   101,
-       0,     0,   139,    71,     0,    74,    86,     0,    87,    88,
-      89,    77,     0,    86,     0,    72,    97,   103,   110,     0,
-       1,   192,     0,   137,     0,     0,   196,    78,    83,    85,
-      90,     0,    92,    79,     0,     0,     2,     5,     4,     6,
-      27,     0,     0,     0,    34,    33,    32,     3,     8,    28,
-      10,    15,    16,     0,     0,    21,     0,    35,     0,    38,
-      41,    42,    47,    50,    51,    52,    53,    55,    57,    59,
-      70,     0,    25,    73,     0,     0,     0,   141,     0,     0,
-     176,     0,     0,     0,     0,     0,   158,   163,   167,    35,
-      61,    68,     0,   149,     0,   114,   152,   165,   151,   150,
-       0,   153,   154,   155,   156,    80,    82,    84,     0,     0,
-      98,     0,   148,   100,    29,    30,     0,    12,    13,     0,
-       0,    19,    18,     0,    20,    22,    24,    31,     0,     0,
+     135,   137,   195,   196,     0,    76,    86,     0,    91,    96,
+       0,   102,     0,   109,   114,   136,     0,   192,   194,   107,
+     101,     0,     0,   140,    71,     0,    74,    86,     0,    87,
+      88,    89,    77,     0,    86,     0,    72,    97,   103,   110,
+       0,     1,   193,     0,   138,     0,     0,   197,    78,    83,
+      85,    90,     0,    92,    79,     0,     0,     2,     5,     4,
+       6,    27,     0,     0,     0,    34,    33,    32,     3,     8,
+      28,    10,    15,    16,     0,     0,    21,     0,    35,     0,
+      38,    41,    42,    47,    50,    51,    52,    53,    55,    57,
+      59,    70,     0,    25,    73,     0,     0,     0,   142,     0,
+       0,   177,     0,     0,     0,     0,     0,   159,   164,   168,
+      35,    61,    68,     0,   150,     0,   114,   153,   166,   152,
+     151,     0,   154,   155,   156,   157,    80,    82,    84,     0,
+       0,    98,     0,   149,   100,    29,    30,     0,    12,    13,
+       0,     0,    19,    18,     0,    20,    22,    24,    31,     0,
        0,     0,     0,     0,     0,     0,     0,     0,     0,     0,
-       0,     0,   115,     0,   146,     0,   144,   140,   142,   187,
-     186,     0,   178,     0,   190,   188,     0,   174,   157,     0,
-      64,    65,    66,    67,    63,     0,     0,   168,   164,   166,
-       0,    93,     0,    95,    99,     7,     0,    14,    26,    11,
-      17,    23,    36,    37,    40,    39,    45,    46,    43,    44,
-      48,    49,    54,    56,    58,     0,   138,     0,     0,   143,
-       0,     0,     0,   189,     0,   159,    62,    69,     0,    94,
-       9,     0,     0,   145,     0,   181,   180,   183,     0,   172,
-       0,     0,     0,    81,    60,   147,     0,   182,     0,     0,
-     171,   169,     0,     0,   160,     0,   184,     0,     0,     0,
-     162,   175,   161,     0,   185,   179,   170,   173,   177
+       0,     0,     0,   115,     0,   147,     0,   145,   141,   143,
+     188,   187,     0,   179,     0,   191,   189,     0,   175,   158,
+       0,    64,    65,    66,    67,    63,     0,     0,   169,   165,
+     167,     0,    93,     0,    95,    99,     7,     0,    14,    26,
+      11,    17,    23,    36,    37,    40,    39,    45,    46,    43,
+      44,    48,    49,    54,    56,    58,     0,   139,     0,     0,
+     144,     0,     0,     0,   190,     0,   160,    62,    69,     0,
+      94,     9,     0,     0,   146,     0,   182,   181,   184,     0,
+     173,     0,     0,     0,    81,    60,   148,     0,   183,     0,
+       0,   172,   170,     0,     0,   161,     0,   185,     0,     0,
+       0,   163,   176,   162,     0,   186,   180,   171,   174,   178
 };
 
 /* YYDEFGOTO[NTERM-NUM].  */
 static const yytype_int16 yydefgoto[] =
 {
-      -1,    97,    98,    99,   226,   100,   101,   102,   103,   104,
-     105,   106,   139,   108,   109,   110,   111,   112,   113,   114,
-     115,   116,   117,   118,   119,   140,   141,   215,   142,   121,
-     143,   144,    33,    34,    35,    78,    61,    62,    79,    36,
-      37,    38,    39,    40,    41,    42,   122,    44,   124,    74,
-     126,   127,   195,   196,   163,   146,   147,   148,   149,   209,
-     272,   291,   292,   150,   151,   152,   281,   271,   153,   254,
-     201,   251,   267,   278,   279,   154,    45,    46,    47,    54
+      -1,    98,    99,   100,   227,   101,   102,   103,   104,   105,
+     106,   107,   140,   109,   110,   111,   112,   113,   114,   115,
+     116,   117,   118,   119,   120,   141,   142,   216,   143,   122,
+     144,   145,    34,    35,    36,    79,    62,    63,    80,    37,
+      38,    39,    40,    41,    42,    43,   123,    45,   125,    75,
+     127,   128,   196,   197,   164,   147,   148,   149,   150,   210,
+     273,   292,   293,   151,   152,   153,   282,   272,   154,   255,
+     202,   252,   268,   279,   280,   155,    46,    47,    48,    55
 };
 
 /* YYPACT[STATE-NUM] -- Index in YYTABLE of the portion describing
    STATE-NUM.  */
-#define YYPACT_NINF -242
+#define YYPACT_NINF -251
 static const yytype_int16 yypact[] =
 {
-    1179,    -6,  -242,  -242,  -242,   151,  -242,  -242,  -242,  -242,
-    -242,  -242,  -242,  -242,  -242,  -242,  -242,  -242,  -242,  -242,
-    -242,  -242,  -242,  -242,  -242,   -39,  -242,  -242,  -242,  -242,
-    -242,  -242,   -69,   -37,   -32,    21,   -61,  -242,    26,  1221,
-    -242,  1282,  -242,   -58,  -242,   207,  -242,  -242,  -242,  -242,
-    1282,    22,  -242,  -242,    33,  -242,    70,    88,  -242,  -242,
-    -242,  -242,  1221,   125,    42,  -242,    -8,  -242,  -242,   961,
-    -242,  -242,    72,  -242,  1221,   286,  -242,  -242,  -242,  -242,
-     117,  1221,   -57,  -242,   766,   961,    94,  -242,  -242,  -242,
-    -242,   961,   961,   961,  -242,  -242,  -242,  -242,  -242,    14,
-    -242,  -242,  -242,    99,   -35,  1026,   101,  -242,   961,   -27,
-      46,  -242,   -21,    56,  -242,  -242,  -242,   115,   119,   -45,
-    -242,   103,  -242,  -242,  1221,   136,  1094,  -242,   102,   104,
-    -242,   111,   116,   105,   831,   118,   112,  -242,  -242,    39,
-    -242,  -242,    17,  -242,   -69,    93,  -242,  -242,  -242,  -242,
-     369,  -242,  -242,  -242,  -242,   122,  -242,  -242,   896,   961,
-    -242,   123,  -242,  -242,  -242,  -242,    10,  -242,  -242,   961,
-    1246,  -242,  -242,   961,   120,  -242,  -242,  -242,   961,   961,
-     961,   961,   961,   961,   961,   961,   961,   961,   961,   961,
-     961,   961,  -242,  1136,   126,    49,  -242,  -242,  -242,  -242,
-    -242,   452,  -242,   961,  -242,  -242,    71,  -242,  -242,   452,
-    -242,  -242,  -242,  -242,  -242,   961,   961,  -242,  -242,  -242,
-     961,  -242,   124,  -242,  -242,  -242,   128,   114,  -242,   129,
-    -242,  -242,  -242,  -242,   -27,   -27,  -242,  -242,  -242,  -242,
-     -21,   -21,  -242,   115,   119,    89,  -242,   961,   136,  -242,
-     150,   618,    11,  -242,   701,   452,  -242,  -242,   130,  -242,
-    -242,   961,   131,  -242,   137,  -242,  -242,   701,   452,   114,
-     152,   148,   145,  -242,  -242,  -242,   961,  -242,   141,   153,
-     208,  -242,   143,   535,  -242,    38,   961,   535,   452,   961,
-    -242,  -242,  -242,   146,   114,  -242,  -242,  -242,  -242
+    1250,   -17,  -251,  -251,  -251,   113,  -251,  -251,  -251,  -251,
+    -251,  -251,  -251,  -251,  -251,  -251,  -251,  -251,  -251,  -251,
+    -251,  -251,  -251,  -251,  -251,   -39,  -251,  -251,  -251,  -251,
+    -251,  -251,  -251,   -65,   -34,   -10,    21,   -32,  -251,    28,
+     207,  -251,  1324,  -251,    56,  -251,  1206,  -251,  -251,  -251,
+    -251,  1324,    74,  -251,  -251,    86,  -251,    71,    95,  -251,
+    -251,  -251,  -251,   207,   119,   120,  -251,   -56,  -251,  -251,
+     971,  -251,  -251,    84,  -251,   207,   287,  -251,  -251,  -251,
+    -251,   124,   207,   -59,  -251,   773,   971,    98,  -251,  -251,
+    -251,  -251,   971,   971,   971,  -251,  -251,  -251,  -251,  -251,
+      35,  -251,  -251,  -251,   100,    -9,  1037,   102,  -251,   971,
+     -27,    -1,  -251,   -24,    99,  -251,  -251,  -251,   112,   111,
+     -51,  -251,   103,  -251,  -251,   207,   135,  1106,  -251,   101,
+     104,  -251,   109,   115,   106,   839,   117,   107,  -251,  -251,
+      39,  -251,  -251,   -11,  -251,   -65,    54,  -251,  -251,  -251,
+    -251,   371,  -251,  -251,  -251,  -251,   116,  -251,  -251,   905,
+     971,  -251,   118,  -251,  -251,  -251,  -251,     8,  -251,  -251,
+     971,  1287,  -251,  -251,   971,   125,  -251,  -251,  -251,   971,
+     971,   971,   971,   971,   971,   971,   971,   971,   971,   971,
+     971,   971,   971,  -251,  1149,   122,    17,  -251,  -251,  -251,
+    -251,  -251,   455,  -251,   971,  -251,  -251,    32,  -251,  -251,
+     455,  -251,  -251,  -251,  -251,  -251,   971,   971,  -251,  -251,
+    -251,   971,  -251,   123,  -251,  -251,  -251,   126,   121,  -251,
+     127,  -251,  -251,  -251,  -251,   -27,   -27,  -251,  -251,  -251,
+    -251,   -24,   -24,  -251,   112,   111,    79,  -251,   971,   135,
+    -251,   151,   623,    11,  -251,   707,   455,  -251,  -251,   128,
+    -251,  -251,   971,   130,  -251,   134,  -251,  -251,   707,   455,
+     121,   147,   136,   131,  -251,  -251,  -251,   971,  -251,   132,
+     142,   200,  -251,   139,   539,  -251,    19,   971,   539,   455,
+     971,  -251,  -251,  -251,   140,   121,  -251,  -251,  -251,  -251
 };
 
 /* YYPGOTO[NTERM-NUM].  */
 static const yytype_int16 yypgoto[] =
 {
-    -242,  -242,  -242,  -242,  -242,  -242,  -242,    77,  -242,  -242,
-    -242,  -242,   -44,  -242,   -63,  -242,   -62,   -17,  -242,  -242,
-    -242,    52,    37,    51,  -242,   -66,   -83,  -242,   -92,   -73,
-       7,     8,  -242,  -242,  -242,   161,   197,   193,   176,  -242,
-    -242,  -241,   -29,   -30,   253,   -22,     0,  -242,  -242,  -242,
-     135,  -122,  -242,    12,  -138,    13,  -140,  -203,  -242,  -242,
-    -242,   -26,   209,    53,    15,  -242,  -242,    -2,  -242,  -242,
-    -242,  -242,  -242,  -242,  -242,  -242,  -242,   224,  -242,  -242
+    -251,  -251,  -251,  -251,  -251,  -251,  -251,    50,  -251,  -251,
+    -251,  -251,   -44,  -251,   -21,  -251,   -62,   -20,  -251,  -251,
+    -251,    34,    36,    33,  -251,   -66,   -83,  -251,   -92,   -73,
+       7,    13,  -251,  -251,  -251,   143,   170,   176,   159,  -251,
+    -251,  -247,   -22,   -30,   237,   -15,     0,  -251,  -251,  -251,
+     129,  -122,  -251,    -6,  -159,    -8,  -140,  -250,  -251,  -251,
+    -251,   -41,   202,    48,     9,  -251,  -251,    -5,  -251,  -251,
+    -251,  -251,  -251,  -251,  -251,  -251,  -251,   213,  -251,  -251
 };
 
 /* YYTABLE[YYPACT[STATE-NUM]].  What to do in state STATE-NUM.  If
    positive, shift that token.  If negative, reduce the rule which
    number is the opposite.  If zero, do what YYDEFACT says.
    If YYTABLE_NINF, syntax error.  */
 #define YYTABLE_NINF -117
 static const yytype_int16 yytable[] =
 {
-      43,   166,   162,   120,   198,    51,    63,    31,    32,    67,
-     219,   161,    53,   270,   190,    69,   158,    64,   120,    68,
-      65,   223,   175,   159,    57,   107,   270,    63,    72,     6,
-       7,    48,    80,   182,   183,    55,    52,   172,    49,    43,
-     107,    43,   206,   173,   125,    43,    56,   164,   165,   191,
-      43,    80,    31,    32,    58,    59,    60,    23,    24,   178,
-     179,   250,    43,    83,   177,    84,   167,   168,   184,   185,
-      66,   198,    85,    57,    43,   145,   162,   227,     6,     7,
-     290,    43,   225,   268,   290,   222,    82,   169,   216,   216,
-     231,   170,   120,   -75,   125,   216,   125,    73,   217,   245,
-     210,   211,   212,    58,    59,    60,    23,    24,    75,   213,
-     293,   252,   186,   187,   107,   219,   216,   234,   235,   214,
-     236,   237,   238,   239,    43,    48,    43,   248,   280,   180,
-     249,   181,   256,   257,   232,   233,   107,   107,   107,   107,
-     107,   107,   107,   107,   107,   107,   107,   258,   296,   216,
-     145,   297,   253,   123,   120,     2,     3,     4,    58,    59,
-      60,   155,   269,   125,   -25,   -26,    69,   216,   261,   240,
-     241,   171,   176,   188,   262,   269,   107,   192,   274,   189,
-     194,   120,   202,   199,   285,   200,   204,   203,   208,   207,
-     264,  -116,   216,    43,   294,   220,   282,   224,   259,   247,
-     -27,   145,   260,   107,   273,   275,   162,    70,   276,   145,
+      44,   224,   167,   163,   121,   199,    52,    32,   271,   191,
+      68,   220,   162,    33,    64,   159,    84,    54,    85,   121,
+      49,   271,   160,   176,    58,    86,   108,    69,    50,     6,
+       7,   183,   184,    81,   291,    64,    73,    53,   291,    56,
+      44,   108,    44,   207,   192,   126,    44,    65,   165,   166,
+      66,    44,    81,    32,    59,    60,    61,    23,    24,    33,
+     179,   180,   251,    44,   173,   178,   185,   186,   217,    57,
+     174,   218,   199,    67,    58,    44,   146,   163,   228,     6,
+       7,   226,    44,   181,   269,   182,   223,   217,   168,   169,
+     217,   232,   294,   121,   -75,   126,   249,   126,   217,   250,
+     246,   211,   212,   213,    59,    60,    61,    23,    24,   170,
+     214,   217,   253,   171,   254,   108,   220,     2,     3,     4,
+     215,   237,   238,   239,   240,    44,   -25,    44,    70,   281,
+      70,   298,    49,   257,   258,   233,   234,   108,   108,   108,
+     108,   108,   108,   108,   108,   108,   108,   108,   259,   297,
+      74,   146,    59,    60,    61,   121,   187,   188,   217,   262,
+     235,   236,    76,   270,   126,    83,   124,   241,   242,   156,
+     -26,   189,   190,   172,   177,   263,   270,   108,   193,   275,
+     195,   203,   121,   200,   209,   286,   201,   204,   205,   208,
+     221,   265,   283,   225,    44,   295,   248,  -116,   260,   -27,
+     217,   261,   146,   274,   108,   276,   277,   163,   285,   284,
+     146,     2,     3,     4,   287,   288,   289,     8,     9,    10,
+     290,   231,   299,   243,   245,   157,   244,    78,    11,    12,
+      13,    14,    15,    16,    17,    18,    19,    20,    21,    22,
+      82,   158,    51,   264,   266,    25,    26,   296,    27,    28,
+      29,    30,   146,    31,   194,   146,   146,    77,   256,    72,
+       0,   267,     0,   278,     0,     0,     0,     0,   146,   146,
+       0,     0,     0,     0,     0,     0,     0,     0,     0,     0,
+       0,     0,     0,     0,   146,     0,     0,     0,   146,   146,
        1,     2,     3,     4,     5,     6,     7,     8,     9,    10,
-     283,   284,   286,   289,   288,   287,   243,   298,    11,    12,
+     129,   130,   131,     0,   132,   133,   134,   135,    11,    12,
       13,    14,    15,    16,    17,    18,    19,    20,    21,    22,
-     242,   244,   156,    23,    24,    25,    26,   230,    27,    28,
-      29,   145,    30,    77,   145,   145,    81,   157,    50,   193,
-     263,   295,   255,    76,   265,   277,   266,   145,   145,    71,
+       0,     0,     0,    23,    24,    25,    26,   136,    27,    28,
+      29,    30,    87,    31,    88,    89,    90,    91,     0,     0,
+      92,    93,     0,     0,     0,     0,     0,     0,     0,     0,
+       0,     0,     0,     0,     0,     0,     0,     0,     0,    94,
+       0,     0,     0,   137,   138,     0,     0,     0,     0,   139,
+      95,    96,     0,    97,     1,     2,     3,     4,     5,     6,
+       7,     8,     9,    10,   129,   130,   131,     0,   132,   133,
+     134,   135,    11,    12,    13,    14,    15,    16,    17,    18,
+      19,    20,    21,    22,     0,     0,     0,    23,    24,    25,
+      26,   136,    27,    28,    29,    30,    87,    31,    88,    89,
+      90,    91,     0,     0,    92,    93,     0,     0,     0,     0,
        0,     0,     0,     0,     0,     0,     0,     0,     0,     0,
-       0,     0,     0,   145,     0,     0,     0,   145,   145,     1,
-       2,     3,     4,     5,     6,     7,     8,     9,    10,   128,
-     129,   130,     0,   131,   132,   133,   134,    11,    12,    13,
-      14,    15,    16,    17,    18,    19,    20,    21,    22,     0,
-       0,     0,    23,    24,    25,    26,   135,    27,    28,    29,
-      86,    30,    87,    88,    89,    90,     0,     0,    91,    92,
+       0,     0,     0,    94,     0,     0,     0,   137,   219,     0,
+       0,     0,     0,   139,    95,    96,     0,    97,     1,     2,
+       3,     4,     5,     6,     7,     8,     9,    10,   129,   130,
+     131,     0,   132,   133,   134,   135,    11,    12,    13,    14,
+      15,    16,    17,    18,    19,    20,    21,    22,     0,     0,
+       0,    23,    24,    25,    26,   136,    27,    28,    29,    30,
+      87,    31,    88,    89,    90,    91,     0,     0,    92,    93,
        0,     0,     0,     0,     0,     0,     0,     0,     0,     0,
-       0,     0,     0,     0,     0,     0,     0,    93,     0,     0,
-       0,   136,   137,     0,     0,     0,     0,   138,    94,    95,
-       0,    96,     1,     2,     3,     4,     5,     6,     7,     8,
-       9,    10,   128,   129,   130,     0,   131,   132,   133,   134,
+       0,     0,     0,     0,     0,     0,     0,    94,     0,     0,
+       0,   137,     0,     0,     0,     0,     0,   139,    95,    96,
+       0,    97,     1,     2,     3,     4,     5,     6,     7,     8,
+       9,    10,   129,   130,   131,     0,   132,   133,   134,   135,
       11,    12,    13,    14,    15,    16,    17,    18,    19,    20,
-      21,    22,     0,     0,     0,    23,    24,    25,    26,   135,
-      27,    28,    29,    86,    30,    87,    88,    89,    90,     0,
-       0,    91,    92,     0,     0,     0,     0,     0,     0,     0,
+      21,    22,     0,     0,     0,    23,    24,    25,    26,   136,
+      27,    28,    29,    30,    87,    31,    88,    89,    90,    91,
+       0,     0,    92,    93,     0,     0,     0,     0,     0,     0,
+       0,     0,     0,     0,     0,     0,     0,     0,     0,     0,
+       0,    94,     0,     0,     0,    76,     0,     0,     0,     0,
+       0,   139,    95,    96,     0,    97,     1,     2,     3,     4,
+       5,     6,     7,     8,     9,    10,     0,     0,     0,     0,
+       0,     0,     0,     0,    11,    12,    13,    14,    15,    16,
+      17,    18,    19,    20,    21,    22,     0,     0,     0,    23,
+      24,    25,    26,     0,    27,    28,    29,    30,    87,    31,
+      88,    89,    90,    91,     0,     0,    92,    93,     0,     0,
        0,     0,     0,     0,     0,     0,     0,     0,     0,     0,
-      93,     0,     0,     0,   136,   218,     0,     0,     0,     0,
-     138,    94,    95,     0,    96,     1,     2,     3,     4,     5,
-       6,     7,     8,     9,    10,   128,   129,   130,     0,   131,
-     132,   133,   134,    11,    12,    13,    14,    15,    16,    17,
-      18,    19,    20,    21,    22,     0,     0,     0,    23,    24,
-      25,    26,   135,    27,    28,    29,    86,    30,    87,    88,
-      89,    90,     0,     0,    91,    92,     0,     0,     0,     0,
-       0,     0,     0,     0,     0,     0,     0,     0,     0,     0,
-       0,     0,     0,    93,     0,     0,     0,   136,     0,     0,
-       0,     0,     0,   138,    94,    95,     0,    96,     1,     2,
-       3,     4,     5,     6,     7,     8,     9,    10,   128,   129,
-     130,     0,   131,   132,   133,   134,    11,    12,    13,    14,
-      15,    16,    17,    18,    19,    20,    21,    22,     0,     0,
-       0,    23,    24,    25,    26,   135,    27,    28,    29,    86,
-      30,    87,    88,    89,    90,     0,     0,    91,    92,     0,
+       0,     0,     0,     0,     0,    94,     0,     0,     0,     0,
+       0,     0,     0,     0,     0,   139,    95,    96,     0,    97,
+      58,     2,     3,     4,     0,     6,     7,     8,     9,    10,
+       0,     0,     0,     0,     0,     0,     0,     0,    11,    12,
+      13,    14,    15,    16,    17,    18,    19,    20,    21,    22,
+       0,     0,     0,    23,    24,    25,    26,     0,    27,    28,
+      29,    30,    87,    31,    88,    89,    90,    91,     0,     0,
+      92,    93,     0,     0,     0,     0,     0,     0,     0,     0,
+       0,     0,     0,     0,     0,     0,     0,     0,     0,    94,
+       0,     0,     0,     8,     9,    10,     0,     0,     0,     0,
+      95,    96,     0,    97,    11,    12,    13,    14,    15,    16,
+      17,    18,    19,    20,    21,    22,     0,     0,     0,     0,
+       0,    25,    26,     0,    27,    28,    29,    30,    87,    31,
+      88,    89,    90,    91,     0,     0,    92,    93,     0,     0,
        0,     0,     0,     0,     0,     0,     0,     0,     0,     0,
-       0,     0,     0,     0,     0,     0,    93,     0,     0,     0,
-      75,     0,     0,     0,     0,     0,   138,    94,    95,     0,
-      96,     1,     2,     3,     4,     5,     6,     7,     8,     9,
-      10,     0,     0,     0,     0,     0,     0,     0,     0,    11,
-      12,    13,    14,    15,    16,    17,    18,    19,    20,    21,
-      22,     0,     0,     0,    23,    24,    25,    26,     0,    27,
-      28,    29,    86,    30,    87,    88,    89,    90,     0,     0,
-      91,    92,     0,     0,     0,     0,     0,     0,     0,     0,
-       0,     0,     0,     0,     0,     0,     0,     0,     0,    93,
-       0,     0,     0,     0,     0,     0,     0,     0,     0,   138,
-      94,    95,     0,    96,    57,     2,     3,     4,     0,     6,
-       7,     8,     9,    10,     0,     0,     0,     0,     0,     0,
-       0,     0,    11,    12,    13,    14,    15,    16,    17,    18,
-      19,    20,    21,    22,     0,     0,     0,    23,    24,    25,
-      26,     0,    27,    28,    29,    86,    30,    87,    88,    89,
-      90,     0,     0,    91,    92,     0,     0,     0,     0,     0,
+       0,     0,     0,     0,     0,    94,     0,     0,   161,     8,
+       9,    10,     0,     0,     0,     0,    95,    96,     0,    97,
+      11,    12,    13,    14,    15,    16,    17,    18,    19,    20,
+      21,    22,     0,     0,     0,     0,     0,    25,    26,     0,
+      27,    28,    29,    30,    87,    31,    88,    89,    90,    91,
+       0,     0,    92,    93,     0,     0,     0,     0,     0,     0,
+       0,     0,     0,     0,     0,     0,     0,     0,     0,     0,
+       0,    94,     0,     0,     0,     8,     9,    10,     0,     0,
+       0,   206,    95,    96,     0,    97,    11,    12,    13,    14,
+      15,    16,    17,    18,    19,    20,    21,    22,     0,     0,
+       0,     0,     0,    25,    26,     0,    27,    28,    29,    30,
+      87,    31,    88,    89,    90,    91,     0,     0,    92,    93,
        0,     0,     0,     0,     0,     0,     0,     0,     0,     0,
-       0,     0,    93,     0,     0,     0,     8,     9,    10,     0,
-       0,     0,     0,    94,    95,     0,    96,    11,    12,    13,
+       0,     0,     0,     0,     0,     0,     0,    94,     0,     0,
+     222,     8,     9,    10,     0,     0,     0,     0,    95,    96,
+       0,    97,    11,    12,    13,    14,    15,    16,    17,    18,
+      19,    20,    21,    22,     0,     0,     0,     0,     0,    25,
+      26,     0,    27,    28,    29,    30,    87,    31,    88,    89,
+      90,    91,     0,     0,    92,    93,     0,     0,     0,     0,
+       0,     0,     0,     0,     0,     0,     0,     0,     0,     0,
+       0,     0,     0,    94,     0,     0,     0,     8,     9,    10,
+       0,     0,     0,     0,    95,    96,     0,    97,    11,    12,
+      13,    14,    15,    16,    17,    18,    19,    20,    21,    22,
+       0,     0,     0,     0,     0,    25,   175,     0,    27,    28,
+      29,    30,    87,    31,    88,    89,    90,    91,     0,     0,
+      92,    93,     0,     0,     0,     0,     0,     0,     0,     0,
+       0,     0,     0,     0,     0,     0,     0,     0,     0,    94,
+       2,     3,     4,     0,     0,     0,     8,     9,    10,     0,
+      95,    96,     0,    97,     0,     0,     0,    11,    12,    13,
       14,    15,    16,    17,    18,    19,    20,    21,    22,     0,
        0,     0,     0,     0,    25,    26,     0,    27,    28,    29,
-      86,    30,    87,    88,    89,    90,     0,     0,    91,    92,
-       0,     0,     0,     0,     0,     0,     0,     0,     0,     0,
-       0,     0,     0,     0,     0,     0,     0,    93,     0,     0,
-     160,     8,     9,    10,     0,     0,     0,     0,    94,    95,
-       0,    96,    11,    12,    13,    14,    15,    16,    17,    18,
-      19,    20,    21,    22,     0,     0,     0,     0,     0,    25,
-      26,     0,    27,    28,    29,    86,    30,    87,    88,    89,
-      90,     0,     0,    91,    92,     0,     0,     0,     0,     0,
-       0,     0,     0,     0,     0,     0,     0,     0,     0,     0,
-       0,     0,    93,     0,     0,     0,     8,     9,    10,     0,
-       0,     0,   205,    94,    95,     0,    96,    11,    12,    13,
-      14,    15,    16,    17,    18,    19,    20,    21,    22,     0,
-       0,     0,     0,     0,    25,    26,     0,    27,    28,    29,
-      86,    30,    87,    88,    89,    90,     0,     0,    91,    92,
-       0,     0,     0,     0,     0,     0,     0,     0,     0,     0,
-       0,     0,     0,     0,     0,     0,     0,    93,     0,     0,
-     221,     8,     9,    10,     0,     0,     0,     0,    94,    95,
-       0,    96,    11,    12,    13,    14,    15,    16,    17,    18,
-      19,    20,    21,    22,     0,     0,     0,     0,     0,    25,
-      26,     0,    27,    28,    29,    86,    30,    87,    88,    89,
-      90,     0,     0,    91,    92,     0,     0,     0,     0,     0,
-       0,     0,     0,     0,     0,     0,     0,     0,     0,     0,
-       0,     0,    93,     0,     0,     0,     8,     9,    10,     0,
-       0,     0,     0,    94,    95,     0,    96,    11,    12,    13,
-      14,    15,    16,    17,    18,    19,    20,    21,    22,     0,
-       0,     0,     0,     0,    25,   174,     0,    27,    28,    29,
-      86,    30,    87,    88,    89,    90,     0,     0,    91,    92,
-       0,     0,     0,     0,     0,     0,     0,     0,     0,     0,
-       0,     0,     0,     0,     0,     0,     0,    93,     2,     3,
-       4,     0,     0,     0,     8,     9,    10,     0,    94,    95,
-       0,    96,     0,     0,     0,    11,    12,    13,    14,    15,
-      16,    17,    18,    19,    20,    21,    22,     0,     0,     0,
-       0,     0,    25,    26,     0,    27,    28,    29,     0,    30,
-       2,     3,     4,     0,     0,     0,     8,     9,    10,     0,
-       0,     0,     0,     0,     0,     0,     0,    11,    12,    13,
-      14,    15,    16,    17,    18,    19,    20,    21,    22,     0,
-     197,     0,     0,     0,    25,    26,     0,    27,    28,    29,
-       0,    30,     1,     2,     3,     4,     5,     6,     7,     8,
+      30,     0,    31,     2,     3,     4,     0,     0,     0,     8,
        9,    10,     0,     0,     0,     0,     0,     0,     0,     0,
       11,    12,    13,    14,    15,    16,    17,    18,    19,    20,
-      21,    22,   246,     0,     0,    23,    24,    25,    26,     0,
-      27,    28,    29,     0,    30,     2,     3,     4,     0,     0,
-       0,     8,     9,    10,     0,     0,     0,     0,     0,     0,
-       0,     0,    11,    12,    13,    14,    15,    16,    17,    18,
-      19,    20,    21,    22,     0,     0,     8,     9,    10,    25,
-      26,     0,    27,    28,    29,     0,    30,    11,    12,    13,
+      21,    22,     0,   198,     0,     0,     0,    25,    26,     0,
+      27,    28,    29,    30,     0,    31,     0,     0,     0,     0,
+       0,     0,     0,     0,     0,     0,    71,     0,     0,     1,
+       2,     3,     4,     5,     6,     7,     8,     9,    10,     0,
+       0,     0,     0,     0,     0,     0,   247,    11,    12,    13,
       14,    15,    16,    17,    18,    19,    20,    21,    22,     0,
-       0,     0,     0,     0,    25,    26,     0,    27,    28,    29,
-     228,    30,     8,     9,    10,   229,     0,     0,     0,     0,
-       0,     0,     0,    11,    12,    13,    14,    15,    16,    17,
-      18,    19,    20,    21,    22,     0,     0,     0,     0,     0,
-      25,    26,     0,    27,    28,    29,     0,    30
+       0,     0,    23,    24,    25,    26,     0,    27,    28,    29,
+      30,     0,    31,     1,     2,     3,     4,     5,     6,     7,
+       8,     9,    10,     0,     0,     0,     0,     0,     0,     0,
+       0,    11,    12,    13,    14,    15,    16,    17,    18,    19,
+      20,    21,    22,     0,     0,     0,    23,    24,    25,    26,
+       0,    27,    28,    29,    30,     0,    31,     8,     9,    10,
+       0,     0,     0,     0,     0,     0,     0,     0,    11,    12,
+      13,    14,    15,    16,    17,    18,    19,    20,    21,    22,
+       0,     0,     0,     0,     0,    25,    26,     0,    27,    28,
+      29,    30,   229,    31,     8,     9,    10,   230,     0,     0,
+       0,     0,     0,     0,     0,    11,    12,    13,    14,    15,
+      16,    17,    18,    19,    20,    21,    22,     0,     0,     0,
+       0,     0,    25,    26,     0,    27,    28,    29,    30,     0,
+      31
 };
 
 static const yytype_int16 yycheck[] =
 {
-       0,    93,    85,    69,   126,    44,    35,     0,     0,    39,
-     150,    84,    81,   254,    59,    73,    73,    78,    84,    41,
-      81,   159,   105,    80,     3,    69,   267,    56,    50,     8,
-       9,    37,    62,    54,    55,    72,    75,    72,    44,    39,
-      84,    41,   134,    78,    74,    45,    78,    91,    92,    94,
-      50,    81,    45,    45,    33,    34,    35,    36,    37,    86,
-      87,   201,    62,    71,   108,    73,    52,    53,    89,    90,
-      44,   193,    80,     3,    74,    75,   159,   169,     8,     9,
-     283,    81,    72,    72,   287,   158,    44,    73,    78,    78,
-     173,    77,   158,    72,   124,    78,   126,    75,    81,   191,
-      61,    62,    63,    33,    34,    35,    36,    37,    75,    70,
-      72,   203,    56,    57,   158,   255,    78,   180,   181,    80,
-     182,   183,   184,   185,   124,    37,   126,    78,   268,    83,
-      81,    85,   215,   216,   178,   179,   180,   181,   182,   183,
-     184,   185,   186,   187,   188,   189,   190,   220,   288,    78,
-     150,   289,    81,    81,   220,     4,     5,     6,    33,    34,
-      35,    44,   254,   193,    71,    71,    73,    78,    79,   186,
-     187,    72,    71,    58,   247,   267,   220,    74,   261,    60,
-      44,   247,    71,    81,   276,    81,    81,    71,    76,    71,
-      40,    71,    78,   193,   286,    73,    44,    74,    74,    73,
-      71,   201,    74,   247,    74,    74,   289,     0,    71,   209,
-       3,     4,     5,     6,     7,     8,     9,    10,    11,    12,
-      72,    76,    81,    80,    16,    72,   189,    81,    21,    22,
+       0,   160,    94,    86,    70,   127,    45,     0,   255,    60,
+      40,   151,    85,     0,    36,    74,    72,    82,    74,    85,
+      37,   268,    81,   106,     3,    81,    70,    42,    45,     8,
+       9,    55,    56,    63,   284,    57,    51,    76,   288,    73,
+      40,    85,    42,   135,    95,    75,    46,    79,    92,    93,
+      82,    51,    82,    46,    33,    34,    35,    36,    37,    46,
+      87,    88,   202,    63,    73,   109,    90,    91,    79,    79,
+      79,    82,   194,    45,     3,    75,    76,   160,   170,     8,
+       9,    73,    82,    84,    73,    86,   159,    79,    53,    54,
+      79,   174,    73,   159,    73,   125,    79,   127,    79,    82,
+     192,    62,    63,    64,    33,    34,    35,    36,    37,    74,
+      71,    79,   204,    78,    82,   159,   256,     4,     5,     6,
+      81,   183,   184,   185,   186,   125,    72,   127,    74,   269,
+      74,   290,    37,   216,   217,   179,   180,   181,   182,   183,
+     184,   185,   186,   187,   188,   189,   190,   191,   221,   289,
+      76,   151,    33,    34,    35,   221,    57,    58,    79,    80,
+     181,   182,    76,   255,   194,    45,    82,   187,   188,    45,
+      72,    59,    61,    73,    72,   248,   268,   221,    75,   262,
+      45,    72,   248,    82,    77,   277,    82,    72,    82,    72,
+      74,    40,    45,    75,   194,   287,    74,    72,    75,    72,
+      79,    75,   202,    75,   248,    75,    72,   290,    77,    73,
+     210,     4,     5,     6,    82,    73,    16,    10,    11,    12,
+      81,   171,    82,   189,   191,    82,   190,    57,    21,    22,
       23,    24,    25,    26,    27,    28,    29,    30,    31,    32,
-     188,   190,    81,    36,    37,    38,    39,   170,    41,    42,
-      43,   251,    45,    56,   254,   255,    63,    81,     5,   124,
-     248,   287,   209,    54,   251,   267,   251,   267,   268,    45,
-      -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,
-      -1,    -1,    -1,   283,    -1,    -1,    -1,   287,   288,     3,
-       4,     5,     6,     7,     8,     9,    10,    11,    12,    13,
-      14,    15,    -1,    17,    18,    19,    20,    21,    22,    23,
-      24,    25,    26,    27,    28,    29,    30,    31,    32,    -1,
-      -1,    -1,    36,    37,    38,    39,    40,    41,    42,    43,
-      44,    45,    46,    47,    48,    49,    -1,    -1,    52,    53,
+      64,    82,     5,   249,   252,    38,    39,   288,    41,    42,
+      43,    44,   252,    46,   125,   255,   256,    55,   210,    46,
+      -1,   252,    -1,   268,    -1,    -1,    -1,    -1,   268,   269,
       -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,
-      -1,    -1,    -1,    -1,    -1,    -1,    -1,    71,    -1,    -1,
-      -1,    75,    76,    -1,    -1,    -1,    -1,    81,    82,    83,
-      -1,    85,     3,     4,     5,     6,     7,     8,     9,    10,
-      11,    12,    13,    14,    15,    -1,    17,    18,    19,    20,
-      21,    22,    23,    24,    25,    26,    27,    28,    29,    30,
-      31,    32,    -1,    -1,    -1,    36,    37,    38,    39,    40,
-      41,    42,    43,    44,    45,    46,    47,    48,    49,    -1,
-      -1,    52,    53,    -1,    -1,    -1,    -1,    -1,    -1,    -1,
+      -1,    -1,    -1,    -1,   284,    -1,    -1,    -1,   288,   289,
+       3,     4,     5,     6,     7,     8,     9,    10,    11,    12,
+      13,    14,    15,    -1,    17,    18,    19,    20,    21,    22,
+      23,    24,    25,    26,    27,    28,    29,    30,    31,    32,
+      -1,    -1,    -1,    36,    37,    38,    39,    40,    41,    42,
+      43,    44,    45,    46,    47,    48,    49,    50,    -1,    -1,
+      53,    54,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,
+      -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    72,
+      -1,    -1,    -1,    76,    77,    -1,    -1,    -1,    -1,    82,
+      83,    84,    -1,    86,     3,     4,     5,     6,     7,     8,
+       9,    10,    11,    12,    13,    14,    15,    -1,    17,    18,
+      19,    20,    21,    22,    23,    24,    25,    26,    27,    28,
+      29,    30,    31,    32,    -1,    -1,    -1,    36,    37,    38,
+      39,    40,    41,    42,    43,    44,    45,    46,    47,    48,
+      49,    50,    -1,    -1,    53,    54,    -1,    -1,    -1,    -1,
       -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,
-      71,    -1,    -1,    -1,    75,    76,    -1,    -1,    -1,    -1,
-      81,    82,    83,    -1,    85,     3,     4,     5,     6,     7,
-       8,     9,    10,    11,    12,    13,    14,    15,    -1,    17,
-      18,    19,    20,    21,    22,    23,    24,    25,    26,    27,
-      28,    29,    30,    31,    32,    -1,    -1,    -1,    36,    37,
-      38,    39,    40,    41,    42,    43,    44,    45,    46,    47,
-      48,    49,    -1,    -1,    52,    53,    -1,    -1,    -1,    -1,
-      -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,
-      -1,    -1,    -1,    71,    -1,    -1,    -1,    75,    -1,    -1,
-      -1,    -1,    -1,    81,    82,    83,    -1,    85,     3,     4,
+      -1,    -1,    -1,    72,    -1,    -1,    -1,    76,    77,    -1,
+      -1,    -1,    -1,    82,    83,    84,    -1,    86,     3,     4,
        5,     6,     7,     8,     9,    10,    11,    12,    13,    14,
       15,    -1,    17,    18,    19,    20,    21,    22,    23,    24,
       25,    26,    27,    28,    29,    30,    31,    32,    -1,    -1,
       -1,    36,    37,    38,    39,    40,    41,    42,    43,    44,
-      45,    46,    47,    48,    49,    -1,    -1,    52,    53,    -1,
+      45,    46,    47,    48,    49,    50,    -1,    -1,    53,    54,
+      -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,
+      -1,    -1,    -1,    -1,    -1,    -1,    -1,    72,    -1,    -1,
+      -1,    76,    -1,    -1,    -1,    -1,    -1,    82,    83,    84,
+      -1,    86,     3,     4,     5,     6,     7,     8,     9,    10,
+      11,    12,    13,    14,    15,    -1,    17,    18,    19,    20,
+      21,    22,    23,    24,    25,    26,    27,    28,    29,    30,
+      31,    32,    -1,    -1,    -1,    36,    37,    38,    39,    40,
+      41,    42,    43,    44,    45,    46,    47,    48,    49,    50,
+      -1,    -1,    53,    54,    -1,    -1,    -1,    -1,    -1,    -1,
+      -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,
+      -1,    72,    -1,    -1,    -1,    76,    -1,    -1,    -1,    -1,
+      -1,    82,    83,    84,    -1,    86,     3,     4,     5,     6,
+       7,     8,     9,    10,    11,    12,    -1,    -1,    -1,    -1,
+      -1,    -1,    -1,    -1,    21,    22,    23,    24,    25,    26,
+      27,    28,    29,    30,    31,    32,    -1,    -1,    -1,    36,
+      37,    38,    39,    -1,    41,    42,    43,    44,    45,    46,
+      47,    48,    49,    50,    -1,    -1,    53,    54,    -1,    -1,
       -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,
-      -1,    -1,    -1,    -1,    -1,    -1,    71,    -1,    -1,    -1,
-      75,    -1,    -1,    -1,    -1,    -1,    81,    82,    83,    -1,
-      85,     3,     4,     5,     6,     7,     8,     9,    10,    11,
-      12,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    21,
-      22,    23,    24,    25,    26,    27,    28,    29,    30,    31,
-      32,    -1,    -1,    -1,    36,    37,    38,    39,    -1,    41,
-      42,    43,    44,    45,    46,    47,    48,    49,    -1,    -1,
-      52,    53,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,
-      -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    71,
-      -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    81,
-      82,    83,    -1,    85,     3,     4,     5,     6,    -1,     8,
-       9,    10,    11,    12,    -1,    -1,    -1,    -1,    -1,    -1,
-      -1,    -1,    21,    22,    23,    24,    25,    26,    27,    28,
-      29,    30,    31,    32,    -1,    -1,    -1,    36,    37,    38,
-      39,    -1,    41,    42,    43,    44,    45,    46,    47,    48,
-      49,    -1,    -1,    52,    53,    -1,    -1,    -1,    -1,    -1,
+      -1,    -1,    -1,    -1,    -1,    72,    -1,    -1,    -1,    -1,
+      -1,    -1,    -1,    -1,    -1,    82,    83,    84,    -1,    86,
+       3,     4,     5,     6,    -1,     8,     9,    10,    11,    12,
+      -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    21,    22,
+      23,    24,    25,    26,    27,    28,    29,    30,    31,    32,
+      -1,    -1,    -1,    36,    37,    38,    39,    -1,    41,    42,
+      43,    44,    45,    46,    47,    48,    49,    50,    -1,    -1,
+      53,    54,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,
+      -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    72,
+      -1,    -1,    -1,    10,    11,    12,    -1,    -1,    -1,    -1,
+      83,    84,    -1,    86,    21,    22,    23,    24,    25,    26,
+      27,    28,    29,    30,    31,    32,    -1,    -1,    -1,    -1,
+      -1,    38,    39,    -1,    41,    42,    43,    44,    45,    46,
+      47,    48,    49,    50,    -1,    -1,    53,    54,    -1,    -1,
       -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,
-      -1,    -1,    71,    -1,    -1,    -1,    10,    11,    12,    -1,
-      -1,    -1,    -1,    82,    83,    -1,    85,    21,    22,    23,
-      24,    25,    26,    27,    28,    29,    30,    31,    32,    -1,
-      -1,    -1,    -1,    -1,    38,    39,    -1,    41,    42,    43,
-      44,    45,    46,    47,    48,    49,    -1,    -1,    52,    53,
+      -1,    -1,    -1,    -1,    -1,    72,    -1,    -1,    75,    10,
+      11,    12,    -1,    -1,    -1,    -1,    83,    84,    -1,    86,
+      21,    22,    23,    24,    25,    26,    27,    28,    29,    30,
+      31,    32,    -1,    -1,    -1,    -1,    -1,    38,    39,    -1,
+      41,    42,    43,    44,    45,    46,    47,    48,    49,    50,
+      -1,    -1,    53,    54,    -1,    -1,    -1,    -1,    -1,    -1,
       -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,
-      -1,    -1,    -1,    -1,    -1,    -1,    -1,    71,    -1,    -1,
-      74,    10,    11,    12,    -1,    -1,    -1,    -1,    82,    83,
-      -1,    85,    21,    22,    23,    24,    25,    26,    27,    28,
+      -1,    72,    -1,    -1,    -1,    10,    11,    12,    -1,    -1,
+      -1,    82,    83,    84,    -1,    86,    21,    22,    23,    24,
+      25,    26,    27,    28,    29,    30,    31,    32,    -1,    -1,
+      -1,    -1,    -1,    38,    39,    -1,    41,    42,    43,    44,
+      45,    46,    47,    48,    49,    50,    -1,    -1,    53,    54,
+      -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,
+      -1,    -1,    -1,    -1,    -1,    -1,    -1,    72,    -1,    -1,
+      75,    10,    11,    12,    -1,    -1,    -1,    -1,    83,    84,
+      -1,    86,    21,    22,    23,    24,    25,    26,    27,    28,
       29,    30,    31,    32,    -1,    -1,    -1,    -1,    -1,    38,
       39,    -1,    41,    42,    43,    44,    45,    46,    47,    48,
-      49,    -1,    -1,    52,    53,    -1,    -1,    -1,    -1,    -1,
+      49,    50,    -1,    -1,    53,    54,    -1,    -1,    -1,    -1,
       -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,
-      -1,    -1,    71,    -1,    -1,    -1,    10,    11,    12,    -1,
-      -1,    -1,    81,    82,    83,    -1,    85,    21,    22,    23,
+      -1,    -1,    -1,    72,    -1,    -1,    -1,    10,    11,    12,
+      -1,    -1,    -1,    -1,    83,    84,    -1,    86,    21,    22,
+      23,    24,    25,    26,    27,    28,    29,    30,    31,    32,
+      -1,    -1,    -1,    -1,    -1,    38,    39,    -1,    41,    42,
+      43,    44,    45,    46,    47,    48,    49,    50,    -1,    -1,
+      53,    54,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,
+      -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    72,
+       4,     5,     6,    -1,    -1,    -1,    10,    11,    12,    -1,
+      83,    84,    -1,    86,    -1,    -1,    -1,    21,    22,    23,
       24,    25,    26,    27,    28,    29,    30,    31,    32,    -1,
       -1,    -1,    -1,    -1,    38,    39,    -1,    41,    42,    43,
-      44,    45,    46,    47,    48,    49,    -1,    -1,    52,    53,
-      -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,
-      -1,    -1,    -1,    -1,    -1,    -1,    -1,    71,    -1,    -1,
-      74,    10,    11,    12,    -1,    -1,    -1,    -1,    82,    83,
-      -1,    85,    21,    22,    23,    24,    25,    26,    27,    28,
-      29,    30,    31,    32,    -1,    -1,    -1,    -1,    -1,    38,
-      39,    -1,    41,    42,    43,    44,    45,    46,    47,    48,
-      49,    -1,    -1,    52,    53,    -1,    -1,    -1,    -1,    -1,
-      -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,
-      -1,    -1,    71,    -1,    -1,    -1,    10,    11,    12,    -1,
-      -1,    -1,    -1,    82,    83,    -1,    85,    21,    22,    23,
-      24,    25,    26,    27,    28,    29,    30,    31,    32,    -1,
-      -1,    -1,    -1,    -1,    38,    39,    -1,    41,    42,    43,
-      44,    45,    46,    47,    48,    49,    -1,    -1,    52,    53,
-      -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,
-      -1,    -1,    -1,    -1,    -1,    -1,    -1,    71,     4,     5,
-       6,    -1,    -1,    -1,    10,    11,    12,    -1,    82,    83,
-      -1,    85,    -1,    -1,    -1,    21,    22,    23,    24,    25,
-      26,    27,    28,    29,    30,    31,    32,    -1,    -1,    -1,
-      -1,    -1,    38,    39,    -1,    41,    42,    43,    -1,    45,
-       4,     5,     6,    -1,    -1,    -1,    10,    11,    12,    -1,
-      -1,    -1,    -1,    -1,    -1,    -1,    -1,    21,    22,    23,
-      24,    25,    26,    27,    28,    29,    30,    31,    32,    -1,
-      76,    -1,    -1,    -1,    38,    39,    -1,    41,    42,    43,
-      -1,    45,     3,     4,     5,     6,     7,     8,     9,    10,
+      44,    -1,    46,     4,     5,     6,    -1,    -1,    -1,    10,
       11,    12,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,
       21,    22,    23,    24,    25,    26,    27,    28,    29,    30,
-      31,    32,    76,    -1,    -1,    36,    37,    38,    39,    -1,
-      41,    42,    43,    -1,    45,     4,     5,     6,    -1,    -1,
-      -1,    10,    11,    12,    -1,    -1,    -1,    -1,    -1,    -1,
-      -1,    -1,    21,    22,    23,    24,    25,    26,    27,    28,
-      29,    30,    31,    32,    -1,    -1,    10,    11,    12,    38,
-      39,    -1,    41,    42,    43,    -1,    45,    21,    22,    23,
+      31,    32,    -1,    77,    -1,    -1,    -1,    38,    39,    -1,
+      41,    42,    43,    44,    -1,    46,    -1,    -1,    -1,    -1,
+      -1,    -1,    -1,    -1,    -1,    -1,     0,    -1,    -1,     3,
+       4,     5,     6,     7,     8,     9,    10,    11,    12,    -1,
+      -1,    -1,    -1,    -1,    -1,    -1,    77,    21,    22,    23,
       24,    25,    26,    27,    28,    29,    30,    31,    32,    -1,
-      -1,    -1,    -1,    -1,    38,    39,    -1,    41,    42,    43,
-      44,    45,    10,    11,    12,    49,    -1,    -1,    -1,    -1,
-      -1,    -1,    -1,    21,    22,    23,    24,    25,    26,    27,
-      28,    29,    30,    31,    32,    -1,    -1,    -1,    -1,    -1,
-      38,    39,    -1,    41,    42,    43,    -1,    45
+      -1,    -1,    36,    37,    38,    39,    -1,    41,    42,    43,
+      44,    -1,    46,     3,     4,     5,     6,     7,     8,     9,
+      10,    11,    12,    -1,    -1,    -1,    -1,    -1,    -1,    -1,
+      -1,    21,    22,    23,    24,    25,    26,    27,    28,    29,
+      30,    31,    32,    -1,    -1,    -1,    36,    37,    38,    39,
+      -1,    41,    42,    43,    44,    -1,    46,    10,    11,    12,
+      -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    21,    22,
+      23,    24,    25,    26,    27,    28,    29,    30,    31,    32,
+      -1,    -1,    -1,    -1,    -1,    38,    39,    -1,    41,    42,
+      43,    44,    45,    46,    10,    11,    12,    50,    -1,    -1,
+      -1,    -1,    -1,    -1,    -1,    21,    22,    23,    24,    25,
+      26,    27,    28,    29,    30,    31,    32,    -1,    -1,    -1,
+      -1,    -1,    38,    39,    -1,    41,    42,    43,    44,    -1,
+      46
 };
 
 /* YYSTOS[STATE-NUM] -- The (internal number of the) accessing
    symbol of state STATE-NUM.  */
 static const yytype_uint8 yystos[] =
 {
        0,     3,     4,     5,     6,     7,     8,     9,    10,    11,
       12,    21,    22,    23,    24,    25,    26,    27,    28,    29,
       30,    31,    32,    36,    37,    38,    39,    41,    42,    43,
-      45,   125,   126,   127,   128,   129,   134,   135,   136,   137,
-     138,   139,   140,   141,   142,   171,   172,   173,    37,    44,
-     139,    44,    75,    81,   174,    72,    78,     3,    33,    34,
-      35,   131,   132,   137,    78,    81,    44,   138,   140,    73,
-       0,   172,   140,    75,   144,    75,   157,   131,   130,   133,
-     138,   132,    44,    71,    73,    80,    44,    46,    47,    48,
-      49,    52,    53,    71,    82,    83,    85,    96,    97,    98,
-     100,   101,   102,   103,   104,   105,   106,   107,   108,   109,
+      44,    46,   126,   127,   128,   129,   130,   135,   136,   137,
+     138,   139,   140,   141,   142,   143,   172,   173,   174,    37,
+      45,   140,    45,    76,    82,   175,    73,    79,     3,    33,
+      34,    35,   132,   133,   138,    79,    82,    45,   139,   141,
+      74,     0,   173,   141,    76,   145,    76,   158,   132,   131,
+     134,   139,   133,    45,    72,    74,    81,    45,    47,    48,
+      49,    50,    53,    54,    72,    83,    84,    86,    97,    98,
+      99,   101,   102,   103,   104,   105,   106,   107,   108,   109,
      110,   111,   112,   113,   114,   115,   116,   117,   118,   119,
-     120,   124,   141,    81,   143,   138,   145,   146,    13,    14,
-      15,    17,    18,    19,    20,    40,    75,    76,    81,   107,
-     120,   121,   123,   125,   126,   141,   150,   151,   152,   153,
-     158,   159,   160,   163,   170,    44,   130,   133,    73,    80,
-      74,   124,   121,   149,   107,   107,   123,    52,    53,    73,
-      77,    72,    72,    78,    39,   121,    71,   107,    86,    87,
-      83,    85,    54,    55,    89,    90,    56,    57,    58,    60,
-      59,    94,    74,   145,    44,   147,   148,    76,   146,    81,
-      81,   165,    71,    71,    81,    81,   123,    71,    76,   154,
-      61,    62,    63,    70,    80,   122,    78,    81,    76,   151,
-      73,    74,   124,   149,    74,    72,    99,   123,    44,    49,
-     102,   121,   107,   107,   109,   109,   111,   111,   111,   111,
-     112,   112,   116,   117,   118,   123,    76,    73,    78,    81,
-     151,   166,   123,    81,   164,   158,   121,   121,   124,    74,
-      74,    79,   124,   148,    40,   150,   159,   167,    72,   123,
-     136,   162,   155,    74,   121,    74,    71,   162,   168,   169,
-     151,   161,    44,    72,    76,   123,    81,    72,    16,    80,
-     152,   156,   157,    72,   123,   156,   151,   149,    81
+     120,   121,   125,   142,    82,   144,   139,   146,   147,    13,
+      14,    15,    17,    18,    19,    20,    40,    76,    77,    82,
+     108,   121,   122,   124,   126,   127,   142,   151,   152,   153,
+     154,   159,   160,   161,   164,   171,    45,   131,   134,    74,
+      81,    75,   125,   122,   150,   108,   108,   124,    53,    54,
+      74,    78,    73,    73,    79,    39,   122,    72,   108,    87,
+      88,    84,    86,    55,    56,    90,    91,    57,    58,    59,
+      61,    60,    95,    75,   146,    45,   148,   149,    77,   147,
+      82,    82,   166,    72,    72,    82,    82,   124,    72,    77,
+     155,    62,    63,    64,    71,    81,   123,    79,    82,    77,
+     152,    74,    75,   125,   150,    75,    73,   100,   124,    45,
+      50,   103,   122,   108,   108,   110,   110,   112,   112,   112,
+     112,   113,   113,   117,   118,   119,   124,    77,    74,    79,
+      82,   152,   167,   124,    82,   165,   159,   122,   122,   125,
+      75,    75,    80,   125,   149,    40,   151,   160,   168,    73,
+     124,   137,   163,   156,    75,   122,    75,    72,   163,   169,
+     170,   152,   162,    45,    73,    77,   124,    82,    73,    16,
+      81,   153,   157,   158,    73,   124,   157,   152,   150,    82
 };
 
 #define yyerrok		(yyerrstatus = 0)
 #define yyclearin	(yychar = YYEMPTY)
 #define YYEMPTY		(-2)
 #define YYEOF		0
 
 #define YYACCEPT	goto yyacceptlab
@@ -1356,17 +1280,17 @@ while (YYID (0))
 #endif
 
 
 /* YY_LOCATION_PRINT -- Print the location on the stream.
    This macro was not mandated originally: define only if we know
    we won't break user code: when these are the locations we know.  */
 
 #ifndef YY_LOCATION_PRINT
-# if defined YYLTYPE_IS_TRIVIAL && YYLTYPE_IS_TRIVIAL
+# if YYLTYPE_IS_TRIVIAL
 #  define YY_LOCATION_PRINT(File, Loc)			\
      fprintf (File, "%d.%d-%d.%d",			\
 	      (Loc).first_line, (Loc).first_column,	\
 	      (Loc).last_line,  (Loc).last_column)
 # else
 #  define YY_LOCATION_PRINT(File, Loc) ((void) 0)
 # endif
 #endif
@@ -1470,27 +1394,30 @@ yy_symbol_print (yyoutput, yytype, yyval
 /*------------------------------------------------------------------.
 | yy_stack_print -- Print the state stack from its BOTTOM up to its |
 | TOP (included).                                                   |
 `------------------------------------------------------------------*/
 
 #if (defined __STDC__ || defined __C99__FUNC__ \
      || defined __cplusplus || defined _MSC_VER)
 static void
-yy_stack_print (yytype_int16 *bottom, yytype_int16 *top)
+yy_stack_print (yytype_int16 *yybottom, yytype_int16 *yytop)
 #else
 static void
-yy_stack_print (bottom, top)
-    yytype_int16 *bottom;
-    yytype_int16 *top;
+yy_stack_print (yybottom, yytop)
+    yytype_int16 *yybottom;
+    yytype_int16 *yytop;
 #endif
 {
   YYFPRINTF (stderr, "Stack now");
-  for (; bottom <= top; ++bottom)
-    YYFPRINTF (stderr, " %d", *bottom);
+  for (; yybottom <= yytop; yybottom++)
+    {
+      int yybot = *yybottom;
+      YYFPRINTF (stderr, " %d", yybot);
+    }
   YYFPRINTF (stderr, "\n");
 }
 
 # define YY_STACK_PRINT(Bottom, Top)				\
 do {								\
   if (yydebug)							\
     yy_stack_print ((Bottom), (Top));				\
 } while (YYID (0))
@@ -1515,21 +1442,21 @@ yy_reduce_print (yyvsp, yyrule, context)
   int yynrhs = yyr2[yyrule];
   int yyi;
   unsigned long int yylno = yyrline[yyrule];
   YYFPRINTF (stderr, "Reducing stack by rule %d (line %lu):\n",
 	     yyrule - 1, yylno);
   /* The symbols being reduced.  */
   for (yyi = 0; yyi < yynrhs; yyi++)
     {
-      fprintf (stderr, "   $%d = ", yyi + 1);
+      YYFPRINTF (stderr, "   $%d = ", yyi + 1);
       yy_symbol_print (stderr, yyrhs[yyprhs[yyrule] + yyi],
 		       &(yyvsp[(yyi + 1) - (yynrhs)])
 		       		       , context);
-      fprintf (stderr, "\n");
+      YYFPRINTF (stderr, "\n");
     }
 }
 
 # define YY_REDUCE_PRINT(Rule)		\
 do {					\
   if (yydebug)				\
     yy_reduce_print (yyvsp, Rule, context); \
 } while (YYID (0))
@@ -1801,20 +1728,18 @@ yydestruct (yymsg, yytype, yyvaluep, con
 
   switch (yytype)
     {
 
       default:
 	break;
     }
 }
-
 
 /* Prevent warnings from -Wmissing-prototypes.  */
-
 #ifdef YYPARSE_PARAM
 #if defined __STDC__ || defined __cplusplus
 int yyparse (void *YYPARSE_PARAM);
 #else
 int yyparse ();
 #endif
 #else /* ! YYPARSE_PARAM */
 #if defined __STDC__ || defined __cplusplus
@@ -1823,20 +1748,19 @@ int yyparse (TParseContext* context);
 int yyparse ();
 #endif
 #endif /* ! YYPARSE_PARAM */
 
 
 
 
 
-
-/*----------.
-| yyparse.  |
-`----------*/
+/*-------------------------.
+| yyparse or yypush_parse.  |
+`-------------------------*/
 
 #ifdef YYPARSE_PARAM
 #if (defined __STDC__ || defined __C99__FUNC__ \
      || defined __cplusplus || defined _MSC_VER)
 int
 yyparse (void *YYPARSE_PARAM)
 #else
 int
@@ -1850,84 +1774,85 @@ int
 yyparse (TParseContext* context)
 #else
 int
 yyparse (context)
     TParseContext* context;
 #endif
 #endif
 {
-  /* The look-ahead symbol.  */
+/* The lookahead symbol.  */
 int yychar;
 
-/* The semantic value of the look-ahead symbol.  */
+/* The semantic value of the lookahead symbol.  */
 YYSTYPE yylval;
 
-/* Number of syntax errors so far.  */
-int yynerrs;
-
-  int yystate;
+    /* Number of syntax errors so far.  */
+    int yynerrs;
+
+    int yystate;
+    /* Number of tokens to shift before error messages enabled.  */
+    int yyerrstatus;
+
+    /* The stacks and their tools:
+       `yyss': related to states.
+       `yyvs': related to semantic values.
+
+       Refer to the stacks thru separate pointers, to allow yyoverflow
+       to reallocate them elsewhere.  */
+
+    /* The state stack.  */
+    yytype_int16 yyssa[YYINITDEPTH];
+    yytype_int16 *yyss;
+    yytype_int16 *yyssp;
+
+    /* The semantic value stack.  */
+    YYSTYPE yyvsa[YYINITDEPTH];
+    YYSTYPE *yyvs;
+    YYSTYPE *yyvsp;
+
+    YYSIZE_T yystacksize;
+
   int yyn;
   int yyresult;
-  /* Number of tokens to shift before error messages enabled.  */
-  int yyerrstatus;
-  /* Look-ahead token as an internal (translated) token number.  */
-  int yytoken = 0;
+  /* Lookahead token as an internal (translated) token number.  */
+  int yytoken;
+  /* The variables used to return semantic value and location from the
+     action routines.  */
+  YYSTYPE yyval;
+
 #if YYERROR_VERBOSE
   /* Buffer for error messages, and its allocated size.  */
   char yymsgbuf[128];
   char *yymsg = yymsgbuf;
   YYSIZE_T yymsg_alloc = sizeof yymsgbuf;
 #endif
 
-  /* Three stacks and their tools:
-     `yyss': related to states,
-     `yyvs': related to semantic values,
-     `yyls': related to locations.
-
-     Refer to the stacks thru separate pointers, to allow yyoverflow
-     to reallocate them elsewhere.  */
-
-  /* The state stack.  */
-  yytype_int16 yyssa[YYINITDEPTH];
-  yytype_int16 *yyss = yyssa;
-  yytype_int16 *yyssp;
-
-  /* The semantic value stack.  */
-  YYSTYPE yyvsa[YYINITDEPTH];
-  YYSTYPE *yyvs = yyvsa;
-  YYSTYPE *yyvsp;
-
-
-
 #define YYPOPSTACK(N)   (yyvsp -= (N), yyssp -= (N))
 
-  YYSIZE_T yystacksize = YYINITDEPTH;
-
-  /* The variables used to return semantic value and location from the
-     action routines.  */
-  YYSTYPE yyval;
-
-
   /* The number of symbols on the RHS of the reduced rule.
      Keep to zero when no symbol should be popped.  */
   int yylen = 0;
 
+  yytoken = 0;
+  yyss = yyssa;
+  yyvs = yyvsa;
+  yystacksize = YYINITDEPTH;
+
   YYDPRINTF ((stderr, "Starting parse\n"));
 
   yystate = 0;
   yyerrstatus = 0;
   yynerrs = 0;
-  yychar = YYEMPTY;		/* Cause a token to be read.  */
+  yychar = YYEMPTY; /* Cause a token to be read.  */
 
   /* Initialize stack pointers.
      Waste one element of value and location stack
      so that they stay on the same level as the state stack.
      The wasted elements are never initialized.  */
-
   yyssp = yyss;
   yyvsp = yyvs;
 
   goto yysetstate;
 
 /*------------------------------------------------------------.
 | yynewstate -- Push a new state, which is found in yystate.  |
 `------------------------------------------------------------*/
@@ -1947,25 +1872,23 @@ int yynerrs;
 #ifdef yyoverflow
       {
 	/* Give user a chance to reallocate the stack.  Use copies of
 	   these so that the &'s don't force the real ones into
 	   memory.  */
 	YYSTYPE *yyvs1 = yyvs;
 	yytype_int16 *yyss1 = yyss;
 
-
 	/* Each stack pointer address is followed by the size of the
 	   data in use in that stack, in bytes.  This used to be a
 	   conditional around just the two extra args, but that might
 	   be undefined if yyoverflow is a macro.  */
 	yyoverflow (YY_("memory exhausted"),
 		    &yyss1, yysize * sizeof (*yyssp),
 		    &yyvs1, yysize * sizeof (*yyvsp),
-
 		    &yystacksize);
 
 	yyss = yyss1;
 	yyvs = yyvs1;
       }
 #else /* no yyoverflow */
 # ifndef YYSTACK_RELOCATE
       goto yyexhaustedlab;
@@ -1978,57 +1901,58 @@ int yynerrs;
 	yystacksize = YYMAXDEPTH;
 
       {
 	yytype_int16 *yyss1 = yyss;
 	union yyalloc *yyptr =
 	  (union yyalloc *) YYSTACK_ALLOC (YYSTACK_BYTES (yystacksize));
 	if (! yyptr)
 	  goto yyexhaustedlab;
-	YYSTACK_RELOCATE (yyss);
-	YYSTACK_RELOCATE (yyvs);
-
+	YYSTACK_RELOCATE (yyss_alloc, yyss);
+	YYSTACK_RELOCATE (yyvs_alloc, yyvs);
 #  undef YYSTACK_RELOCATE
 	if (yyss1 != yyssa)
 	  YYSTACK_FREE (yyss1);
       }
 # endif
 #endif /* no yyoverflow */
 
       yyssp = yyss + yysize - 1;
       yyvsp = yyvs + yysize - 1;
 
-
       YYDPRINTF ((stderr, "Stack size increased to %lu\n",
 		  (unsigned long int) yystacksize));
 
       if (yyss + yystacksize - 1 <= yyssp)
 	YYABORT;
     }
 
   YYDPRINTF ((stderr, "Entering state %d\n", yystate));
 
+  if (yystate == YYFINAL)
+    YYACCEPT;
+
   goto yybackup;
 
 /*-----------.
 | yybackup.  |
 `-----------*/
 yybackup:
 
   /* Do appropriate processing given the current state.  Read a
-     look-ahead token if we need one and don't already have one.  */
-
-  /* First try to decide what to do without reference to look-ahead token.  */
+     lookahead token if we need one and don't already have one.  */
+
+  /* First try to decide what to do without reference to lookahead token.  */
   yyn = yypact[yystate];
   if (yyn == YYPACT_NINF)
     goto yydefault;
 
-  /* Not known => get a look-ahead token if don't already have one.  */
-
-  /* YYCHAR is either YYEMPTY or YYEOF or a valid look-ahead symbol.  */
+  /* Not known => get a lookahead token if don't already have one.  */
+
+  /* YYCHAR is either YYEMPTY or YYEOF or a valid lookahead symbol.  */
   if (yychar == YYEMPTY)
     {
       YYDPRINTF ((stderr, "Reading a token: "));
       yychar = YYLEX;
     }
 
   if (yychar <= YYEOF)
     {
@@ -2050,30 +1974,26 @@ yybackup:
   if (yyn <= 0)
     {
       if (yyn == 0 || yyn == YYTABLE_NINF)
 	goto yyerrlab;
       yyn = -yyn;
       goto yyreduce;
     }
 
-  if (yyn == YYFINAL)
-    YYACCEPT;
-
   /* Count tokens shifted since error; after three, turn off error
      status.  */
   if (yyerrstatus)
     yyerrstatus--;
 
-  /* Shift the look-ahead token.  */
+  /* Shift the lookahead token.  */
   YY_SYMBOL_PRINT ("Shifting", yytoken, &yylval, &yylloc);
 
-  /* Discard the shifted token unless it is eof.  */
-  if (yychar != YYEOF)
-    yychar = YYEMPTY;
+  /* Discard the shifted token.  */
+  yychar = YYEMPTY;
 
   yystate = yyn;
   *++yyvsp = yylval;
 
   goto yynewstate;
 
 
 /*-----------------------------------------------------------.
@@ -2135,73 +2055,73 @@ yyreduce:
         if (variable->getType().getQualifier() == EvqConst ) {
             ConstantUnion* constArray = variable->getConstPointer();
             TType t(variable->getType());
             (yyval.interm.intermTypedNode) = context->intermediate.addConstantUnion(constArray, t, (yyvsp[(1) - (1)].lex).line);
         } else
             (yyval.interm.intermTypedNode) = context->intermediate.addSymbol(variable->getUniqueId(),
                                                      variable->getName(),
                                                      variable->getType(), (yyvsp[(1) - (1)].lex).line);
-    ;}
+    }
     break;
 
   case 3:
 
     {
         (yyval.interm.intermTypedNode) = (yyvsp[(1) - (1)].interm.intermTypedNode);
-    ;}
+    }
     break;
 
   case 4:
 
     {
         //
         // INT_TYPE is only 16-bit plus sign bit for vertex/fragment shaders,
         // check for overflow for constants
         //
         if (abs((yyvsp[(1) - (1)].lex).i) >= (1 << 16)) {
             context->error((yyvsp[(1) - (1)].lex).line, " integer constant overflow", "", "");
             context->recover();
         }
         ConstantUnion *unionArray = new ConstantUnion[1];
         unionArray->setIConst((yyvsp[(1) - (1)].lex).i);
         (yyval.interm.intermTypedNode) = context->intermediate.addConstantUnion(unionArray, TType(EbtInt, EbpUndefined, EvqConst), (yyvsp[(1) - (1)].lex).line);
-    ;}
+    }
     break;
 
   case 5:
 
     {
         ConstantUnion *unionArray = new ConstantUnion[1];
         unionArray->setFConst((yyvsp[(1) - (1)].lex).f);
         (yyval.interm.intermTypedNode) = context->intermediate.addConstantUnion(unionArray, TType(EbtFloat, EbpUndefined, EvqConst), (yyvsp[(1) - (1)].lex).line);
-    ;}
+    }
     break;
 
   case 6:
 
     {
         ConstantUnion *unionArray = new ConstantUnion[1];
         unionArray->setBConst((yyvsp[(1) - (1)].lex).b);
         (yyval.interm.intermTypedNode) = context->intermediate.addConstantUnion(unionArray, TType(EbtBool, EbpUndefined, EvqConst), (yyvsp[(1) - (1)].lex).line);
-    ;}
+    }
     break;
 
   case 7:
 
     {
         (yyval.interm.intermTypedNode) = (yyvsp[(2) - (3)].interm.intermTypedNode);
-    ;}
+    }
     break;
 
   case 8:
 
     {
         (yyval.interm.intermTypedNode) = (yyvsp[(1) - (1)].interm.intermTypedNode);
-    ;}
+    }
     break;
 
   case 9:
 
     {
         if (!(yyvsp[(1) - (4)].interm.intermTypedNode)->isArray() && !(yyvsp[(1) - (4)].interm.intermTypedNode)->isMatrix() && !(yyvsp[(1) - (4)].interm.intermTypedNode)->isVector()) {
             if ((yyvsp[(1) - (4)].interm.intermTypedNode)->getAsSymbolNode())
                 context->error((yyvsp[(2) - (4)].lex).line, " left of '[' is not of type array, matrix, or vector ", (yyvsp[(1) - (4)].interm.intermTypedNode)->getAsSymbolNode()->getSymbol().c_str(), "");
@@ -2268,24 +2188,24 @@ yyreduce:
         else if ((yyvsp[(1) - (4)].interm.intermTypedNode)->isMatrix())
             (yyval.interm.intermTypedNode)->setType(TType((yyvsp[(1) - (4)].interm.intermTypedNode)->getBasicType(), (yyvsp[(1) - (4)].interm.intermTypedNode)->getPrecision(), EvqTemporary, (yyvsp[(1) - (4)].interm.intermTypedNode)->getNominalSize()));
         else if ((yyvsp[(1) - (4)].interm.intermTypedNode)->isVector() && (yyvsp[(1) - (4)].interm.intermTypedNode)->getType().getQualifier() == EvqConst)
             (yyval.interm.intermTypedNode)->setType(TType((yyvsp[(1) - (4)].interm.intermTypedNode)->getBasicType(), (yyvsp[(1) - (4)].interm.intermTypedNode)->getPrecision(), EvqConst));
         else if ((yyvsp[(1) - (4)].interm.intermTypedNode)->isVector())
             (yyval.interm.intermTypedNode)->setType(TType((yyvsp[(1) - (4)].interm.intermTypedNode)->getBasicType(), (yyvsp[(1) - (4)].interm.intermTypedNode)->getPrecision(), EvqTemporary));
         else
             (yyval.interm.intermTypedNode)->setType((yyvsp[(1) - (4)].interm.intermTypedNode)->getType());
-    ;}
+    }
     break;
 
   case 10:
 
     {
         (yyval.interm.intermTypedNode) = (yyvsp[(1) - (1)].interm.intermTypedNode);
-    ;}
+    }
     break;
 
   case 11:
 
     {
         if ((yyvsp[(1) - (3)].interm.intermTypedNode)->isArray()) {
             context->error((yyvsp[(3) - (3)].lex).line, "cannot apply dot operator to an array", ".", "");
             context->recover();
@@ -2388,54 +2308,54 @@ yyreduce:
                 }
             }
         } else {
             context->error((yyvsp[(2) - (3)].lex).line, " field selection requires structure, vector, or matrix on left hand side", (yyvsp[(3) - (3)].lex).string->c_str(), "");
             context->recover();
             (yyval.interm.intermTypedNode) = (yyvsp[(1) - (3)].interm.intermTypedNode);
         }
         // don't delete $3.string, it's from the pool
-    ;}
+    }
     break;
 
   case 12:
 
     {
         if (context->lValueErrorCheck((yyvsp[(2) - (2)].lex).line, "++", (yyvsp[(1) - (2)].interm.intermTypedNode)))
             context->recover();
         (yyval.interm.intermTypedNode) = context->intermediate.addUnaryMath(EOpPostIncrement, (yyvsp[(1) - (2)].interm.intermTypedNode), (yyvsp[(2) - (2)].lex).line, context->symbolTable);
         if ((yyval.interm.intermTypedNode) == 0) {
             context->unaryOpError((yyvsp[(2) - (2)].lex).line, "++", (yyvsp[(1) - (2)].interm.intermTypedNode)->getCompleteString());
             context->recover();
             (yyval.interm.intermTypedNode) = (yyvsp[(1) - (2)].interm.intermTypedNode);
         }
-    ;}
+    }
     break;
 
   case 13:
 
     {
         if (context->lValueErrorCheck((yyvsp[(2) - (2)].lex).line, "--", (yyvsp[(1) - (2)].interm.intermTypedNode)))
             context->recover();
         (yyval.interm.intermTypedNode) = context->intermediate.addUnaryMath(EOpPostDecrement, (yyvsp[(1) - (2)].interm.intermTypedNode), (yyvsp[(2) - (2)].lex).line, context->symbolTable);
         if ((yyval.interm.intermTypedNode) == 0) {
             context->unaryOpError((yyvsp[(2) - (2)].lex).line, "--", (yyvsp[(1) - (2)].interm.intermTypedNode)->getCompleteString());
             context->recover();
             (yyval.interm.intermTypedNode) = (yyvsp[(1) - (2)].interm.intermTypedNode);
         }
-    ;}
+    }
     break;
 
   case 14:
 
     {
         if (context->integerErrorCheck((yyvsp[(1) - (1)].interm.intermTypedNode), "[]"))
             context->recover();
         (yyval.interm.intermTypedNode) = (yyvsp[(1) - (1)].interm.intermTypedNode);
-    ;}
+    }
     break;
 
   case 15:
 
     {
         TFunction* fnCall = (yyvsp[(1) - (1)].interm).function;
         TOperator op = fnCall->getBuiltInOp();
 
@@ -2525,92 +2445,92 @@ yyreduce:
                 // Put on a dummy node for error recovery
                 ConstantUnion *unionArray = new ConstantUnion[1];
                 unionArray->setFConst(0.0f);
                 (yyval.interm.intermTypedNode) = context->intermediate.addConstantUnion(unionArray, TType(EbtFloat, EbpUndefined, EvqConst), (yyvsp[(1) - (1)].interm).line);
                 context->recover();
             }
         }
         delete fnCall;
-    ;}
+    }
     break;
 
   case 16:
 
     {
         (yyval.interm) = (yyvsp[(1) - (1)].interm);
-    ;}
+    }
     break;
 
   case 17:
 
     {
         context->error((yyvsp[(3) - (3)].interm).line, "methods are not supported", "", "");
         context->recover();
         (yyval.interm) = (yyvsp[(3) - (3)].interm);
-    ;}
+    }
     break;
 
   case 18:
 
     {
         (yyval.interm) = (yyvsp[(1) - (2)].interm);
         (yyval.interm).line = (yyvsp[(2) - (2)].lex).line;
-    ;}
+    }
     break;
 
   case 19:
 
     {
         (yyval.interm) = (yyvsp[(1) - (2)].interm);
         (yyval.interm).line = (yyvsp[(2) - (2)].lex).line;
-    ;}
+    }
     break;
 
   case 20:
 
     {
         (yyval.interm).function = (yyvsp[(1) - (2)].interm.function);
         (yyval.interm).intermNode = 0;
-    ;}
+    }
     break;
 
   case 21:
 
     {
         (yyval.interm).function = (yyvsp[(1) - (1)].interm.function);
         (yyval.interm).intermNode = 0;
-    ;}
+    }
     break;
 
   case 22:
 
     {
         TParameter param = { 0, new TType((yyvsp[(2) - (2)].interm.intermTypedNode)->getType()) };
         (yyvsp[(1) - (2)].interm.function)->addParameter(param);
         (yyval.interm).function = (yyvsp[(1) - (2)].interm.function);
         (yyval.interm).intermNode = (yyvsp[(2) - (2)].interm.intermTypedNode);
-    ;}
+    }
     break;
 
   case 23:
 
     {
         TParameter param = { 0, new TType((yyvsp[(3) - (3)].interm.intermTypedNode)->getType()) };
         (yyvsp[(1) - (3)].interm).function->addParameter(param);
         (yyval.interm).function = (yyvsp[(1) - (3)].interm).function;
         (yyval.interm).intermNode = context->intermediate.growAggregate((yyvsp[(1) - (3)].interm).intermNode, (yyvsp[(3) - (3)].interm.intermTypedNode), (yyvsp[(2) - (3)].lex).line);
-    ;}
+    }
     break;
 
   case 24:
 
     {
         (yyval.interm.function) = (yyvsp[(1) - (2)].interm.function);
-    ;}
+    }
     break;
 
   case 25:
 
     {
         //
         // Constructor
         //
@@ -2659,74 +2579,74 @@ yyreduce:
                 (yyvsp[(1) - (1)].interm.type).type = EbtFloat;
                 op = EOpConstructFloat;
             }
         }
         TString tempString;
         TType type((yyvsp[(1) - (1)].interm.type));
         TFunction *function = new TFunction(&tempString, type, op);
         (yyval.interm.function) = function;
-    ;}
+    }
     break;
 
   case 26:
 
     {
         if (context->reservedErrorCheck((yyvsp[(1) - (1)].lex).line, *(yyvsp[(1) - (1)].lex).string))
             context->recover();
         TType type(EbtVoid, EbpUndefined);
         TFunction *function = new TFunction((yyvsp[(1) - (1)].lex).string, type);
         (yyval.interm.function) = function;
-    ;}
+    }
     break;
 
   case 27:
 
     {
         if (context->reservedErrorCheck((yyvsp[(1) - (1)].lex).line, *(yyvsp[(1) - (1)].lex).string))
             context->recover();
         TType type(EbtVoid, EbpUndefined);
         TFunction *function = new TFunction((yyvsp[(1) - (1)].lex).string, type);
         (yyval.interm.function) = function;
-    ;}
+    }
     break;
 
   case 28:
 
     {
         (yyval.interm.intermTypedNode) = (yyvsp[(1) - (1)].interm.intermTypedNode);
-    ;}
+    }
     break;
 
   case 29:
 
     {
         if (context->lValueErrorCheck((yyvsp[(1) - (2)].lex).line, "++", (yyvsp[(2) - (2)].interm.intermTypedNode)))
             context->recover();
         (yyval.interm.intermTypedNode) = context->intermediate.addUnaryMath(EOpPreIncrement, (yyvsp[(2) - (2)].interm.intermTypedNode), (yyvsp[(1) - (2)].lex).line, context->symbolTable);
         if ((yyval.interm.intermTypedNode) == 0) {
             context->unaryOpError((yyvsp[(1) - (2)].lex).line, "++", (yyvsp[(2) - (2)].interm.intermTypedNode)->getCompleteString());
             context->recover();
             (yyval.interm.intermTypedNode) = (yyvsp[(2) - (2)].interm.intermTypedNode);
         }
-    ;}
+    }
     break;
 
   case 30:
 
     {
         if (context->lValueErrorCheck((yyvsp[(1) - (2)].lex).line, "--", (yyvsp[(2) - (2)].interm.intermTypedNode)))
             context->recover();
         (yyval.interm.intermTypedNode) = context->intermediate.addUnaryMath(EOpPreDecrement, (yyvsp[(2) - (2)].interm.intermTypedNode), (yyvsp[(1) - (2)].lex).line, context->symbolTable);
         if ((yyval.interm.intermTypedNode) == 0) {
             context->unaryOpError((yyvsp[(1) - (2)].lex).line, "--", (yyvsp[(2) - (2)].interm.intermTypedNode)->getCompleteString());
             context->recover();
             (yyval.interm.intermTypedNode) = (yyvsp[(2) - (2)].interm.intermTypedNode);
         }
-    ;}
+    }
     break;
 
   case 31:
 
     {
         if ((yyvsp[(1) - (2)].interm).op != EOpNull) {
             (yyval.interm.intermTypedNode) = context->intermediate.addUnaryMath((yyvsp[(1) - (2)].interm).op, (yyvsp[(2) - (2)].interm.intermTypedNode), (yyvsp[(1) - (2)].interm).line, context->symbolTable);
             if ((yyval.interm.intermTypedNode) == 0) {
@@ -2737,268 +2657,268 @@ yyreduce:
                 default: break;
                 }
                 context->unaryOpError((yyvsp[(1) - (2)].interm).line, errorOp, (yyvsp[(2) - (2)].interm.intermTypedNode)->getCompleteString());
                 context->recover();
                 (yyval.interm.intermTypedNode) = (yyvsp[(2) - (2)].interm.intermTypedNode);
             }
         } else
             (yyval.interm.intermTypedNode) = (yyvsp[(2) - (2)].interm.intermTypedNode);
-    ;}
+    }
     break;
 
   case 32:
 
-    { (yyval.interm).line = (yyvsp[(1) - (1)].lex).line; (yyval.interm).op = EOpNull; ;}
+    { (yyval.interm).line = (yyvsp[(1) - (1)].lex).line; (yyval.interm).op = EOpNull; }
     break;
 
   case 33:
 
-    { (yyval.interm).line = (yyvsp[(1) - (1)].lex).line; (yyval.interm).op = EOpNegative; ;}
+    { (yyval.interm).line = (yyvsp[(1) - (1)].lex).line; (yyval.interm).op = EOpNegative; }
     break;
 
   case 34:
 
-    { (yyval.interm).line = (yyvsp[(1) - (1)].lex).line; (yyval.interm).op = EOpLogicalNot; ;}
+    { (yyval.interm).line = (yyvsp[(1) - (1)].lex).line; (yyval.interm).op = EOpLogicalNot; }
     break;
 
   case 35:
 
-    { (yyval.interm.intermTypedNode) = (yyvsp[(1) - (1)].interm.intermTypedNode); ;}
+    { (yyval.interm.intermTypedNode) = (yyvsp[(1) - (1)].interm.intermTypedNode); }
     break;
 
   case 36:
 
     {
         FRAG_VERT_ONLY("*", (yyvsp[(2) - (3)].lex).line);
         (yyval.interm.intermTypedNode) = context->intermediate.addBinaryMath(EOpMul, (yyvsp[(1) - (3)].interm.intermTypedNode), (yyvsp[(3) - (3)].interm.intermTypedNode), (yyvsp[(2) - (3)].lex).line, context->symbolTable);
         if ((yyval.interm.intermTypedNode) == 0) {
             context->binaryOpError((yyvsp[(2) - (3)].lex).line, "*", (yyvsp[(1) - (3)].interm.intermTypedNode)->getCompleteString(), (yyvsp[(3) - (3)].interm.intermTypedNode)->getCompleteString());
             context->recover();
             (yyval.interm.intermTypedNode) = (yyvsp[(1) - (3)].interm.intermTypedNode);
         }
-    ;}
+    }
     break;
 
   case 37:
 
     {
         FRAG_VERT_ONLY("/", (yyvsp[(2) - (3)].lex).line);
         (yyval.interm.intermTypedNode) = context->intermediate.addBinaryMath(EOpDiv, (yyvsp[(1) - (3)].interm.intermTypedNode), (yyvsp[(3) - (3)].interm.intermTypedNode), (yyvsp[(2) - (3)].lex).line, context->symbolTable);
         if ((yyval.interm.intermTypedNode) == 0) {
             context->binaryOpError((yyvsp[(2) - (3)].lex).line, "/", (yyvsp[(1) - (3)].interm.intermTypedNode)->getCompleteString(), (yyvsp[(3) - (3)].interm.intermTypedNode)->getCompleteString());
             context->recover();
             (yyval.interm.intermTypedNode) = (yyvsp[(1) - (3)].interm.intermTypedNode);
         }
-    ;}
+    }
     break;
 
   case 38:
 
-    { (yyval.interm.intermTypedNode) = (yyvsp[(1) - (1)].interm.intermTypedNode); ;}
+    { (yyval.interm.intermTypedNode) = (yyvsp[(1) - (1)].interm.intermTypedNode); }
     break;
 
   case 39:
 
     {
         (yyval.interm.intermTypedNode) = context->intermediate.addBinaryMath(EOpAdd, (yyvsp[(1) - (3)].interm.intermTypedNode), (yyvsp[(3) - (3)].interm.intermTypedNode), (yyvsp[(2) - (3)].lex).line, context->symbolTable);
         if ((yyval.interm.intermTypedNode) == 0) {
             context->binaryOpError((yyvsp[(2) - (3)].lex).line, "+", (yyvsp[(1) - (3)].interm.intermTypedNode)->getCompleteString(), (yyvsp[(3) - (3)].interm.intermTypedNode)->getCompleteString());
             context->recover();
             (yyval.interm.intermTypedNode) = (yyvsp[(1) - (3)].interm.intermTypedNode);
         }
-    ;}
+    }
     break;
 
   case 40:
 
     {
         (yyval.interm.intermTypedNode) = context->intermediate.addBinaryMath(EOpSub, (yyvsp[(1) - (3)].interm.intermTypedNode), (yyvsp[(3) - (3)].interm.intermTypedNode), (yyvsp[(2) - (3)].lex).line, context->symbolTable);
         if ((yyval.interm.intermTypedNode) == 0) {
             context->binaryOpError((yyvsp[(2) - (3)].lex).line, "-", (yyvsp[(1) - (3)].interm.intermTypedNode)->getCompleteString(), (yyvsp[(3) - (3)].interm.intermTypedNode)->getCompleteString());
             context->recover();
             (yyval.interm.intermTypedNode) = (yyvsp[(1) - (3)].interm.intermTypedNode);
         }
-    ;}
+    }
     break;
 
   case 41:
 
-    { (yyval.interm.intermTypedNode) = (yyvsp[(1) - (1)].interm.intermTypedNode); ;}
+    { (yyval.interm.intermTypedNode) = (yyvsp[(1) - (1)].interm.intermTypedNode); }
     break;
 
   case 42:
 
-    { (yyval.interm.intermTypedNode) = (yyvsp[(1) - (1)].interm.intermTypedNode); ;}
+    { (yyval.interm.intermTypedNode) = (yyvsp[(1) - (1)].interm.intermTypedNode); }
     break;
 
   case 43:
 
     {
         (yyval.interm.intermTypedNode) = context->intermediate.addBinaryMath(EOpLessThan, (yyvsp[(1) - (3)].interm.intermTypedNode), (yyvsp[(3) - (3)].interm.intermTypedNode), (yyvsp[(2) - (3)].lex).line, context->symbolTable);
         if ((yyval.interm.intermTypedNode) == 0) {
             context->binaryOpError((yyvsp[(2) - (3)].lex).line, "<", (yyvsp[(1) - (3)].interm.intermTypedNode)->getCompleteString(), (yyvsp[(3) - (3)].interm.intermTypedNode)->getCompleteString());
             context->recover();
             ConstantUnion *unionArray = new ConstantUnion[1];
             unionArray->setBConst(false);
             (yyval.interm.intermTypedNode) = context->intermediate.addConstantUnion(unionArray, TType(EbtBool, EbpUndefined, EvqConst), (yyvsp[(2) - (3)].lex).line);
         }
-    ;}
+    }
     break;
 
   case 44:
 
     {
         (yyval.interm.intermTypedNode) = context->intermediate.addBinaryMath(EOpGreaterThan, (yyvsp[(1) - (3)].interm.intermTypedNode), (yyvsp[(3) - (3)].interm.intermTypedNode), (yyvsp[(2) - (3)].lex).line, context->symbolTable);
         if ((yyval.interm.intermTypedNode) == 0) {
             context->binaryOpError((yyvsp[(2) - (3)].lex).line, ">", (yyvsp[(1) - (3)].interm.intermTypedNode)->getCompleteString(), (yyvsp[(3) - (3)].interm.intermTypedNode)->getCompleteString());
             context->recover();
             ConstantUnion *unionArray = new ConstantUnion[1];
             unionArray->setBConst(false);
             (yyval.interm.intermTypedNode) = context->intermediate.addConstantUnion(unionArray, TType(EbtBool, EbpUndefined, EvqConst), (yyvsp[(2) - (3)].lex).line);
         }
-    ;}
+    }
     break;
 
   case 45:
 
     {
         (yyval.interm.intermTypedNode) = context->intermediate.addBinaryMath(EOpLessThanEqual, (yyvsp[(1) - (3)].interm.intermTypedNode), (yyvsp[(3) - (3)].interm.intermTypedNode), (yyvsp[(2) - (3)].lex).line, context->symbolTable);
         if ((yyval.interm.intermTypedNode) == 0) {
             context->binaryOpError((yyvsp[(2) - (3)].lex).line, "<=", (yyvsp[(1) - (3)].interm.intermTypedNode)->getCompleteString(), (yyvsp[(3) - (3)].interm.intermTypedNode)->getCompleteString());
             context->recover();
             ConstantUnion *unionArray = new ConstantUnion[1];
             unionArray->setBConst(false);
             (yyval.interm.intermTypedNode) = context->intermediate.addConstantUnion(unionArray, TType(EbtBool, EbpUndefined, EvqConst), (yyvsp[(2) - (3)].lex).line);
         }
-    ;}
+    }
     break;
 
   case 46:
 
     {
         (yyval.interm.intermTypedNode) = context->intermediate.addBinaryMath(EOpGreaterThanEqual, (yyvsp[(1) - (3)].interm.intermTypedNode), (yyvsp[(3) - (3)].interm.intermTypedNode), (yyvsp[(2) - (3)].lex).line, context->symbolTable);
         if ((yyval.interm.intermTypedNode) == 0) {
             context->binaryOpError((yyvsp[(2) - (3)].lex).line, ">=", (yyvsp[(1) - (3)].interm.intermTypedNode)->getCompleteString(), (yyvsp[(3) - (3)].interm.intermTypedNode)->getCompleteString());
             context->recover();
             ConstantUnion *unionArray = new ConstantUnion[1];
             unionArray->setBConst(false);
             (yyval.interm.intermTypedNode) = context->intermediate.addConstantUnion(unionArray, TType(EbtBool, EbpUndefined, EvqConst), (yyvsp[(2) - (3)].lex).line);
         }
-    ;}
+    }
     break;
 
   case 47:
 
-    { (yyval.interm.intermTypedNode) = (yyvsp[(1) - (1)].interm.intermTypedNode); ;}
+    { (yyval.interm.intermTypedNode) = (yyvsp[(1) - (1)].interm.intermTypedNode); }
     break;
 
   case 48:
 
     {
         (yyval.interm.intermTypedNode) = context->intermediate.addBinaryMath(EOpEqual, (yyvsp[(1) - (3)].interm.intermTypedNode), (yyvsp[(3) - (3)].interm.intermTypedNode), (yyvsp[(2) - (3)].lex).line, context->symbolTable);
         if ((yyval.interm.intermTypedNode) == 0) {
             context->binaryOpError((yyvsp[(2) - (3)].lex).line, "==", (yyvsp[(1) - (3)].interm.intermTypedNode)->getCompleteString(), (yyvsp[(3) - (3)].interm.intermTypedNode)->getCompleteString());
             context->recover();
             ConstantUnion *unionArray = new ConstantUnion[1];
             unionArray->setBConst(false);
             (yyval.interm.intermTypedNode) = context->intermediate.addConstantUnion(unionArray, TType(EbtBool, EbpUndefined, EvqConst), (yyvsp[(2) - (3)].lex).line);
         }
-    ;}
+    }
     break;
 
   case 49:
 
     {
         (yyval.interm.intermTypedNode) = context->intermediate.addBinaryMath(EOpNotEqual, (yyvsp[(1) - (3)].interm.intermTypedNode), (yyvsp[(3) - (3)].interm.intermTypedNode), (yyvsp[(2) - (3)].lex).line, context->symbolTable);
         if ((yyval.interm.intermTypedNode) == 0) {
             context->binaryOpError((yyvsp[(2) - (3)].lex).line, "!=", (yyvsp[(1) - (3)].interm.intermTypedNode)->getCompleteString(), (yyvsp[(3) - (3)].interm.intermTypedNode)->getCompleteString());
             context->recover();
             ConstantUnion *unionArray = new ConstantUnion[1];
             unionArray->setBConst(false);
             (yyval.interm.intermTypedNode) = context->intermediate.addConstantUnion(unionArray, TType(EbtBool, EbpUndefined, EvqConst), (yyvsp[(2) - (3)].lex).line);
         }
-    ;}
+    }
     break;
 
   case 50:
 
-    { (yyval.interm.intermTypedNode) = (yyvsp[(1) - (1)].interm.intermTypedNode); ;}
+    { (yyval.interm.intermTypedNode) = (yyvsp[(1) - (1)].interm.intermTypedNode); }
     break;
 
   case 51:
 
-    { (yyval.interm.intermTypedNode) = (yyvsp[(1) - (1)].interm.intermTypedNode); ;}
+    { (yyval.interm.intermTypedNode) = (yyvsp[(1) - (1)].interm.intermTypedNode); }
     break;
 
   case 52:
 
-    { (yyval.interm.intermTypedNode) = (yyvsp[(1) - (1)].interm.intermTypedNode); ;}
+    { (yyval.interm.intermTypedNode) = (yyvsp[(1) - (1)].interm.intermTypedNode); }
     break;
 
   case 53:
 
-    { (yyval.interm.intermTypedNode) = (yyvsp[(1) - (1)].interm.intermTypedNode); ;}
+    { (yyval.interm.intermTypedNode) = (yyvsp[(1) - (1)].interm.intermTypedNode); }
     break;
 
   case 54:
 
     {
         (yyval.interm.intermTypedNode) = context->intermediate.addBinaryMath(EOpLogicalAnd, (yyvsp[(1) - (3)].interm.intermTypedNode), (yyvsp[(3) - (3)].interm.intermTypedNode), (yyvsp[(2) - (3)].lex).line, context->symbolTable);
         if ((yyval.interm.intermTypedNode) == 0) {
             context->binaryOpError((yyvsp[(2) - (3)].lex).line, "&&", (yyvsp[(1) - (3)].interm.intermTypedNode)->getCompleteString(), (yyvsp[(3) - (3)].interm.intermTypedNode)->getCompleteString());
             context->recover();
             ConstantUnion *unionArray = new ConstantUnion[1];
             unionArray->setBConst(false);
             (yyval.interm.intermTypedNode) = context->intermediate.addConstantUnion(unionArray, TType(EbtBool, EbpUndefined, EvqConst), (yyvsp[(2) - (3)].lex).line);
         }
-    ;}
+    }
     break;
 
   case 55:
 
-    { (yyval.interm.intermTypedNode) = (yyvsp[(1) - (1)].interm.intermTypedNode); ;}
+    { (yyval.interm.intermTypedNode) = (yyvsp[(1) - (1)].interm.intermTypedNode); }
     break;
 
   case 56:
 
     {
         (yyval.interm.intermTypedNode) = context->intermediate.addBinaryMath(EOpLogicalXor, (yyvsp[(1) - (3)].interm.intermTypedNode), (yyvsp[(3) - (3)].interm.intermTypedNode), (yyvsp[(2) - (3)].lex).line, context->symbolTable);
         if ((yyval.interm.intermTypedNode) == 0) {
             context->binaryOpError((yyvsp[(2) - (3)].lex).line, "^^", (yyvsp[(1) - (3)].interm.intermTypedNode)->getCompleteString(), (yyvsp[(3) - (3)].interm.intermTypedNode)->getCompleteString());
             context->recover();
             ConstantUnion *unionArray = new ConstantUnion[1];
             unionArray->setBConst(false);
             (yyval.interm.intermTypedNode) = context->intermediate.addConstantUnion(unionArray, TType(EbtBool, EbpUndefined, EvqConst), (yyvsp[(2) - (3)].lex).line);
         }
-    ;}
+    }
     break;
 
   case 57:
 
-    { (yyval.interm.intermTypedNode) = (yyvsp[(1) - (1)].interm.intermTypedNode); ;}
+    { (yyval.interm.intermTypedNode) = (yyvsp[(1) - (1)].interm.intermTypedNode); }
     break;
 
   case 58:
 
     {
         (yyval.interm.intermTypedNode) = context->intermediate.addBinaryMath(EOpLogicalOr, (yyvsp[(1) - (3)].interm.intermTypedNode), (yyvsp[(3) - (3)].interm.intermTypedNode), (yyvsp[(2) - (3)].lex).line, context->symbolTable);
         if ((yyval.interm.intermTypedNode) == 0) {
             context->binaryOpError((yyvsp[(2) - (3)].lex).line, "||", (yyvsp[(1) - (3)].interm.intermTypedNode)->getCompleteString(), (yyvsp[(3) - (3)].interm.intermTypedNode)->getCompleteString());
             context->recover();
             ConstantUnion *unionArray = new ConstantUnion[1];
             unionArray->setBConst(false);
             (yyval.interm.intermTypedNode) = context->intermediate.addConstantUnion(unionArray, TType(EbtBool, EbpUndefined, EvqConst), (yyvsp[(2) - (3)].lex).line);
         }
-    ;}
+    }
     break;
 
   case 59:
 
-    { (yyval.interm.intermTypedNode) = (yyvsp[(1) - (1)].interm.intermTypedNode); ;}
+    { (yyval.interm.intermTypedNode) = (yyvsp[(1) - (1)].interm.intermTypedNode); }
     break;
 
   case 60:
 
     {
        if (context->boolErrorCheck((yyvsp[(2) - (5)].lex).line, (yyvsp[(1) - (5)].interm.intermTypedNode)))
             context->recover();
 
@@ -3006,89 +2926,89 @@ yyreduce:
         if ((yyvsp[(3) - (5)].interm.intermTypedNode)->getType() != (yyvsp[(5) - (5)].interm.intermTypedNode)->getType())
             (yyval.interm.intermTypedNode) = 0;
 
         if ((yyval.interm.intermTypedNode) == 0) {
             context->binaryOpError((yyvsp[(2) - (5)].lex).line, ":", (yyvsp[(3) - (5)].interm.intermTypedNode)->getCompleteString(), (yyvsp[(5) - (5)].interm.intermTypedNode)->getCompleteString());
             context->recover();
             (yyval.interm.intermTypedNode) = (yyvsp[(5) - (5)].interm.intermTypedNode);
         }
-    ;}
+    }
     break;
 
   case 61:
 
-    { (yyval.interm.intermTypedNode) = (yyvsp[(1) - (1)].interm.intermTypedNode); ;}
+    { (yyval.interm.intermTypedNode) = (yyvsp[(1) - (1)].interm.intermTypedNode); }
     break;
 
   case 62:
 
     {
         if (context->lValueErrorCheck((yyvsp[(2) - (3)].interm).line, "assign", (yyvsp[(1) - (3)].interm.intermTypedNode)))
             context->recover();
         (yyval.interm.intermTypedNode) = context->intermediate.addAssign((yyvsp[(2) - (3)].interm).op, (yyvsp[(1) - (3)].interm.intermTypedNode), (yyvsp[(3) - (3)].interm.intermTypedNode), (yyvsp[(2) - (3)].interm).line);
         if ((yyval.interm.intermTypedNode) == 0) {
             context->assignError((yyvsp[(2) - (3)].interm).line, "assign", (yyvsp[(1) - (3)].interm.intermTypedNode)->getCompleteString(), (yyvsp[(3) - (3)].interm.intermTypedNode)->getCompleteString());
             context->recover();
             (yyval.interm.intermTypedNode) = (yyvsp[(1) - (3)].interm.intermTypedNode);
         }
-    ;}
+    }
     break;
 
   case 63:
 
-    {                                    (yyval.interm).line = (yyvsp[(1) - (1)].lex).line; (yyval.interm).op = EOpAssign; ;}
+    {                                    (yyval.interm).line = (yyvsp[(1) - (1)].lex).line; (yyval.interm).op = EOpAssign; }
     break;
 
   case 64:
 
-    { FRAG_VERT_ONLY("*=", (yyvsp[(1) - (1)].lex).line);     (yyval.interm).line = (yyvsp[(1) - (1)].lex).line; (yyval.interm).op = EOpMulAssign; ;}
+    { FRAG_VERT_ONLY("*=", (yyvsp[(1) - (1)].lex).line);     (yyval.interm).line = (yyvsp[(1) - (1)].lex).line; (yyval.interm).op = EOpMulAssign; }
     break;
 
   case 65:
 
-    { FRAG_VERT_ONLY("/=", (yyvsp[(1) - (1)].lex).line);     (yyval.interm).line = (yyvsp[(1) - (1)].lex).line; (yyval.interm).op = EOpDivAssign; ;}
+    { FRAG_VERT_ONLY("/=", (yyvsp[(1) - (1)].lex).line);     (yyval.interm).line = (yyvsp[(1) - (1)].lex).line; (yyval.interm).op = EOpDivAssign; }
     break;
 
   case 66:
 
-    {                                    (yyval.interm).line = (yyvsp[(1) - (1)].lex).line; (yyval.interm).op = EOpAddAssign; ;}
+    {                                    (yyval.interm).line = (yyvsp[(1) - (1)].lex).line; (yyval.interm).op = EOpAddAssign; }
     break;
 
   case 67:
 
-    {                                    (yyval.interm).line = (yyvsp[(1) - (1)].lex).line; (yyval.interm).op = EOpSubAssign; ;}
+    {                                    (yyval.interm).line = (yyvsp[(1) - (1)].lex).line; (yyval.interm).op = EOpSubAssign; }
     break;
 
   case 68:
 
     {
         (yyval.interm.intermTypedNode) = (yyvsp[(1) - (1)].interm.intermTypedNode);
-    ;}
+    }
     break;
 
   case 69:
 
     {
         (yyval.interm.intermTypedNode) = context->intermediate.addComma((yyvsp[(1) - (3)].interm.intermTypedNode), (yyvsp[(3) - (3)].interm.intermTypedNode), (yyvsp[(2) - (3)].lex).line);
         if ((yyval.interm.intermTypedNode) == 0) {
             context->binaryOpError((yyvsp[(2) - (3)].lex).line, ",", (yyvsp[(1) - (3)].interm.intermTypedNode)->getCompleteString(), (yyvsp[(3) - (3)].interm.intermTypedNode)->getCompleteString());
             context->recover();
             (yyval.interm.intermTypedNode) = (yyvsp[(3) - (3)].interm.intermTypedNode);
         }
-    ;}
+    }
     break;
 
   case 70:
 
     {
         if (context->constErrorCheck((yyvsp[(1) - (1)].interm.intermTypedNode)))
             context->recover();
         (yyval.interm.intermTypedNode) = (yyvsp[(1) - (1)].interm.intermTypedNode);
-    ;}
+    }
     break;
 
   case 71:
 
     {
         TFunction &function = *((yyvsp[(1) - (2)].interm).function);
         
         TIntermAggregate *prototype = new TIntermAggregate;
@@ -3107,34 +3027,34 @@ yyreduce:
             else
             {
                 prototype = context->intermediate.growAggregate(prototype, context->intermediate.addSymbol(0, "", *param.type, (yyvsp[(1) - (2)].interm).line), (yyvsp[(1) - (2)].interm).line);
             }
         }
         
         prototype->setOp(EOpPrototype);
         (yyval.interm.intermNode) = prototype;
-    ;}
+    }
     break;
 
   case 72:
 
     {
         if ((yyvsp[(1) - (2)].interm).intermAggregate)
             (yyvsp[(1) - (2)].interm).intermAggregate->setOp(EOpDeclaration);
         (yyval.interm.intermNode) = (yyvsp[(1) - (2)].interm).intermAggregate;
-    ;}
+    }
     break;
 
   case 73:
 
     {
         context->symbolTable.setDefaultPrecision( (yyvsp[(3) - (4)].interm.type).type, (yyvsp[(2) - (4)].interm.precision) );
         (yyval.interm.intermNode) = 0;
-    ;}
+    }
     break;
 
   case 74:
 
     {
         //
         // Multiple declarations of the same function are allowed.
         //
@@ -3161,43 +3081,43 @@ yyreduce:
         // If this is a redeclaration, it could also be a definition,
         // in which case, we want to use the variable names from this one, and not the one that's
         // being redeclared.  So, pass back up this declaration, not the one in the symbol table.
         //
         (yyval.interm).function = (yyvsp[(1) - (2)].interm.function);
         (yyval.interm).line = (yyvsp[(2) - (2)].lex).line;
 
         context->symbolTable.insert(*(yyval.interm).function);
-    ;}
+    }
     break;
 
   case 75:
 
     {
         (yyval.interm.function) = (yyvsp[(1) - (1)].interm.function);
-    ;}
+    }
     break;
 
   case 76:
 
     {
         (yyval.interm.function) = (yyvsp[(1) - (1)].interm.function);
-    ;}
+    }
     break;
 
   case 77:
 
     {
         // Add the parameter
         (yyval.interm.function) = (yyvsp[(1) - (2)].interm.function);
         if ((yyvsp[(2) - (2)].interm).param.type->getBasicType() != EbtVoid)
             (yyvsp[(1) - (2)].interm.function)->addParameter((yyvsp[(2) - (2)].interm).param);
         else
             delete (yyvsp[(2) - (2)].interm).param.type;
-    ;}
+    }
     break;
 
   case 78:
 
     {
         //
         // Only first parameter of one-parameter functions can be void
         // The check for named parameters not being void is done in parameter_declarator
@@ -3209,17 +3129,17 @@ yyreduce:
             context->error((yyvsp[(2) - (3)].lex).line, "cannot be an argument type except for '(void)'", "void", "");
             context->recover();
             delete (yyvsp[(3) - (3)].interm).param.type;
         } else {
             // Add the parameter
             (yyval.interm.function) = (yyvsp[(1) - (3)].interm.function);
             (yyvsp[(1) - (3)].interm.function)->addParameter((yyvsp[(3) - (3)].interm).param);
         }
-    ;}
+    }
     break;
 
   case 79:
 
     {
         if ((yyvsp[(1) - (3)].interm.type).qualifier != EvqGlobal && (yyvsp[(1) - (3)].interm.type).qualifier != EvqTemporary) {
             context->error((yyvsp[(2) - (3)].lex).line, "no qualifiers allowed for function return", getQualifierString((yyvsp[(1) - (3)].interm.type).qualifier), "");
             context->recover();
@@ -3228,32 +3148,32 @@ yyreduce:
         if (context->structQualifierErrorCheck((yyvsp[(2) - (3)].lex).line, (yyvsp[(1) - (3)].interm.type)))
             context->recover();
 
         // Add the function as a prototype after parsing it (we do not support recursion)
         TFunction *function;
         TType type((yyvsp[(1) - (3)].interm.type));
         function = new TFunction((yyvsp[(2) - (3)].lex).string, type);
         (yyval.interm.function) = function;
-    ;}
+    }
     break;
 
   case 80:
 
     {
         if ((yyvsp[(1) - (2)].interm.type).type == EbtVoid) {
             context->error((yyvsp[(2) - (2)].lex).line, "illegal use of type 'void'", (yyvsp[(2) - (2)].lex).string->c_str(), "");
             context->recover();
         }
         if (context->reservedErrorCheck((yyvsp[(2) - (2)].lex).line, *(yyvsp[(2) - (2)].lex).string))
             context->recover();
         TParameter param = {(yyvsp[(2) - (2)].lex).string, new TType((yyvsp[(1) - (2)].interm.type))};
         (yyval.interm).line = (yyvsp[(2) - (2)].lex).line;
         (yyval.interm).param = param;
-    ;}
+    }
     break;
 
   case 81:
 
     {
         // Check that we can make an array out of this type
         if (context->arrayTypeErrorCheck((yyvsp[(3) - (5)].lex).line, (yyvsp[(1) - (5)].interm.type)))
             context->recover();
@@ -3265,100 +3185,100 @@ yyreduce:
         if (context->arraySizeErrorCheck((yyvsp[(3) - (5)].lex).line, (yyvsp[(4) - (5)].interm.intermTypedNode), size))
             context->recover();
         (yyvsp[(1) - (5)].interm.type).setArray(true, size);
 
         TType* type = new TType((yyvsp[(1) - (5)].interm.type));
         TParameter param = { (yyvsp[(2) - (5)].lex).string, type };
         (yyval.interm).line = (yyvsp[(2) - (5)].lex).line;
         (yyval.interm).param = param;
-    ;}
+    }
     break;
 
   case 82:
 
     {
         (yyval.interm) = (yyvsp[(3) - (3)].interm);
         if (context->paramErrorCheck((yyvsp[(3) - (3)].interm).line, (yyvsp[(1) - (3)].interm.type).qualifier, (yyvsp[(2) - (3)].interm.qualifier), (yyval.interm).param.type))
             context->recover();
-    ;}
+    }
     break;
 
   case 83:
 
     {
         (yyval.interm) = (yyvsp[(2) - (2)].interm);
         if (context->parameterSamplerErrorCheck((yyvsp[(2) - (2)].interm).line, (yyvsp[(1) - (2)].interm.qualifier), *(yyvsp[(2) - (2)].interm).param.type))
             context->recover();
         if (context->paramErrorCheck((yyvsp[(2) - (2)].interm).line, EvqTemporary, (yyvsp[(1) - (2)].interm.qualifier), (yyval.interm).param.type))
             context->recover();
-    ;}
+    }
     break;
 
   case 84:
 
     {
         (yyval.interm) = (yyvsp[(3) - (3)].interm);
         if (context->paramErrorCheck((yyvsp[(3) - (3)].interm).line, (yyvsp[(1) - (3)].interm.type).qualifier, (yyvsp[(2) - (3)].interm.qualifier), (yyval.interm).param.type))
             context->recover();
-    ;}
+    }
     break;
 
   case 85:
 
     {
         (yyval.interm) = (yyvsp[(2) - (2)].interm);
         if (context->parameterSamplerErrorCheck((yyvsp[(2) - (2)].interm).line, (yyvsp[(1) - (2)].interm.qualifier), *(yyvsp[(2) - (2)].interm).param.type))
             context->recover();
         if (context->paramErrorCheck((yyvsp[(2) - (2)].interm).line, EvqTemporary, (yyvsp[(1) - (2)].interm.qualifier), (yyval.interm).param.type))
             context->recover();
-    ;}
+    }
     break;
 
   case 86:
 
     {
         (yyval.interm.qualifier) = EvqIn;
-    ;}
+    }
     break;
 
   case 87:
 
     {
         (yyval.interm.qualifier) = EvqIn;
-    ;}
+    }
     break;
 
   case 88:
 
     {
         (yyval.interm.qualifier) = EvqOut;
-    ;}
+    }
     break;
 
   case 89:
 
     {
         (yyval.interm.qualifier) = EvqInOut;
-    ;}
+    }
     break;
 
   case 90:
 
     {
         TParameter param = { 0, new TType((yyvsp[(1) - (1)].interm.type)) };
         (yyval.interm).param = param;
-    ;}
+    }
     break;
 
   case 91:
 
     {
         (yyval.interm) = (yyvsp[(1) - (1)].interm);
-    ;}
+    }
     break;
 
   case 92:
 
     {
         TIntermSymbol* symbol = context->intermediate.addSymbol(0, *(yyvsp[(3) - (3)].lex).string, TType((yyvsp[(1) - (3)].interm).type), (yyvsp[(3) - (3)].lex).line);
         (yyval.interm).intermAggregate = context->intermediate.growAggregate((yyvsp[(1) - (3)].interm).intermNode, symbol, (yyvsp[(3) - (3)].lex).line);
         
@@ -3368,17 +3288,17 @@ yyreduce:
         if (context->nonInitConstErrorCheck((yyvsp[(3) - (3)].lex).line, *(yyvsp[(3) - (3)].lex).string, (yyval.interm).type))
             context->recover();
 
         TVariable* variable = 0;
         if (context->nonInitErrorCheck((yyvsp[(3) - (3)].lex).line, *(yyvsp[(3) - (3)].lex).string, (yyval.interm).type, variable))
             context->recover();
         if (symbol && variable)
             symbol->setId(variable->getUniqueId());
-    ;}
+    }
     break;
 
   case 93:
 
     {
         if (context->structQualifierErrorCheck((yyvsp[(3) - (5)].lex).line, (yyvsp[(1) - (5)].interm).type))
             context->recover();
 
@@ -3390,17 +3310,17 @@ yyreduce:
         if (context->arrayTypeErrorCheck((yyvsp[(4) - (5)].lex).line, (yyvsp[(1) - (5)].interm).type) || context->arrayQualifierErrorCheck((yyvsp[(4) - (5)].lex).line, (yyvsp[(1) - (5)].interm).type))
             context->recover();
         else {
             (yyvsp[(1) - (5)].interm).type.setArray(true);
             TVariable* variable;
             if (context->arrayErrorCheck((yyvsp[(4) - (5)].lex).line, *(yyvsp[(3) - (5)].lex).string, (yyvsp[(1) - (5)].interm).type, variable))
                 context->recover();
         }
-    ;}
+    }
     break;
 
   case 94:
 
     {
         if (context->structQualifierErrorCheck((yyvsp[(3) - (6)].lex).line, (yyvsp[(1) - (6)].interm).type))
             context->recover();
 
@@ -3418,17 +3338,17 @@ yyreduce:
             (yyvsp[(1) - (6)].interm).type.setArray(true, size);
             TVariable* variable = 0;
             if (context->arrayErrorCheck((yyvsp[(4) - (6)].lex).line, *(yyvsp[(3) - (6)].lex).string, (yyvsp[(1) - (6)].interm).type, variable))
                 context->recover();
             TType type = TType((yyvsp[(1) - (6)].interm).type);
             type.setArraySize(size);
             (yyval.interm).intermAggregate = context->intermediate.growAggregate((yyvsp[(1) - (6)].interm).intermNode, context->intermediate.addSymbol(variable ? variable->getUniqueId() : 0, *(yyvsp[(3) - (6)].lex).string, type, (yyvsp[(3) - (6)].lex).line), (yyvsp[(3) - (6)].lex).line);
         }
-    ;}
+    }
     break;
 
   case 95:
 
     {
         if (context->structQualifierErrorCheck((yyvsp[(3) - (5)].lex).line, (yyvsp[(1) - (5)].interm).type))
             context->recover();
 
@@ -3442,25 +3362,25 @@ yyreduce:
             if (intermNode)
         (yyval.interm).intermAggregate = context->intermediate.growAggregate((yyvsp[(1) - (5)].interm).intermNode, intermNode, (yyvsp[(4) - (5)].lex).line);
             else
                 (yyval.interm).intermAggregate = (yyvsp[(1) - (5)].interm).intermAggregate;
         } else {
             context->recover();
             (yyval.interm).intermAggregate = 0;
         }
-    ;}
+    }
     break;
 
   case 96:
 
     {
         (yyval.interm).type = (yyvsp[(1) - (1)].interm.type);
         (yyval.interm).intermAggregate = context->intermediate.makeAggregate(context->intermediate.addSymbol(0, "", TType((yyvsp[(1) - (1)].interm.type)), (yyvsp[(1) - (1)].interm.type).line), (yyvsp[(1) - (1)].interm.type).line);
-    ;}
+    }
     break;
 
   case 97:
 
     {
         TIntermSymbol* symbol = context->intermediate.addSymbol(0, *(yyvsp[(2) - (2)].lex).string, TType((yyvsp[(1) - (2)].interm.type)), (yyvsp[(2) - (2)].lex).line);
         (yyval.interm).intermAggregate = context->intermediate.makeAggregate(symbol, (yyvsp[(2) - (2)].lex).line);
         
@@ -3472,29 +3392,29 @@ yyreduce:
             
             (yyval.interm).type = (yyvsp[(1) - (2)].interm.type);
 
         TVariable* variable = 0;
         if (context->nonInitErrorCheck((yyvsp[(2) - (2)].lex).line, *(yyvsp[(2) - (2)].lex).string, (yyval.interm).type, variable))
             context->recover();
         if (variable && symbol)
             symbol->setId(variable->getUniqueId());
-    ;}
+    }
     break;
 
   case 98:
 
     {
         context->error((yyvsp[(2) - (4)].lex).line, "unsized array declarations not supported", (yyvsp[(2) - (4)].lex).string->c_str(), "");
         context->recover();
 
         TIntermSymbol* symbol = context->intermediate.addSymbol(0, *(yyvsp[(2) - (4)].lex).string, TType((yyvsp[(1) - (4)].interm.type)), (yyvsp[(2) - (4)].lex).line);
         (yyval.interm).intermAggregate = context->intermediate.makeAggregate(symbol, (yyvsp[(2) - (4)].lex).line);
         (yyval.interm).type = (yyvsp[(1) - (4)].interm.type);
-    ;}
+    }
     break;
 
   case 99:
 
     {
         TType type = TType((yyvsp[(1) - (5)].interm.type));
         int size;
         if (context->arraySizeErrorCheck((yyvsp[(2) - (5)].lex).line, (yyvsp[(4) - (5)].interm.intermTypedNode), size))
@@ -3520,17 +3440,17 @@ yyreduce:
 
             (yyvsp[(1) - (5)].interm.type).setArray(true, size);
             TVariable* variable = 0;
             if (context->arrayErrorCheck((yyvsp[(3) - (5)].lex).line, *(yyvsp[(2) - (5)].lex).string, (yyvsp[(1) - (5)].interm.type), variable))
                 context->recover();
             if (variable && symbol)
                 symbol->setId(variable->getUniqueId());
         }
-    ;}
+    }
     break;
 
   case 100:
 
     {
         if (context->structQualifierErrorCheck((yyvsp[(2) - (4)].lex).line, (yyvsp[(1) - (4)].interm.type)))
             context->recover();
 
@@ -3544,39 +3464,39 @@ yyreduce:
             if(intermNode)
                 (yyval.interm).intermAggregate = context->intermediate.makeAggregate(intermNode, (yyvsp[(3) - (4)].lex).line);
             else
                 (yyval.interm).intermAggregate = 0;
         } else {
             context->recover();
             (yyval.interm).intermAggregate = 0;
         }
-    ;}
+    }
     break;
 
   case 101:
 
     {
         VERTEX_ONLY("invariant declaration", (yyvsp[(1) - (2)].lex).line);
         (yyval.interm).qualifier = EvqInvariantVaryingOut;
         (yyval.interm).intermAggregate = 0;
-    ;}
+    }
     break;
 
   case 102:
 
     {
         (yyval.interm.type) = (yyvsp[(1) - (1)].interm.type);
 
         if ((yyvsp[(1) - (1)].interm.type).array) {
             context->error((yyvsp[(1) - (1)].interm.type).line, "not supported", "first-class array", "");
             context->recover();
             (yyvsp[(1) - (1)].interm.type).setArray(false);
         }
-    ;}
+    }
     break;
 
   case 103:
 
     {
         if ((yyvsp[(2) - (2)].interm.type).array) {
             context->error((yyvsp[(2) - (2)].interm.type).line, "not supported", "first-class array", "");
             context->recover();
@@ -3590,394 +3510,407 @@ yyreduce:
         }
         if (((yyvsp[(1) - (2)].interm.type).qualifier == EvqVaryingIn || (yyvsp[(1) - (2)].interm.type).qualifier == EvqVaryingOut) &&
             ((yyvsp[(2) - (2)].interm.type).type == EbtBool || (yyvsp[(2) - (2)].interm.type).type == EbtInt)) {
             context->error((yyvsp[(2) - (2)].interm.type).line, "cannot be bool or int", getQualifierString((yyvsp[(1) - (2)].interm.type).qualifier), "");
             context->recover();
         }
         (yyval.interm.type) = (yyvsp[(2) - (2)].interm.type);
         (yyval.interm.type).qualifier = (yyvsp[(1) - (2)].interm.type).qualifier;
-    ;}
+    }
     break;
 
   case 104:
 
     {
         (yyval.interm.type).setBasic(EbtVoid, EvqConst, (yyvsp[(1) - (1)].lex).line);
-    ;}
+    }
     break;
 
   case 105:
 
     {
         VERTEX_ONLY("attribute", (yyvsp[(1) - (1)].lex).line);
         if (context->globalErrorCheck((yyvsp[(1) - (1)].lex).line, context->symbolTable.atGlobalLevel(), "attribute"))
             context->recover();
         (yyval.interm.type).setBasic(EbtVoid, EvqAttribute, (yyvsp[(1) - (1)].lex).line);
-    ;}
+    }
     break;
 
   case 106:
 
     {
         if (context->globalErrorCheck((yyvsp[(1) - (1)].lex).line, context->symbolTable.atGlobalLevel(), "varying"))
             context->recover();
         if (context->shaderType == SH_VERTEX_SHADER)
             (yyval.interm.type).setBasic(EbtVoid, EvqVaryingOut, (yyvsp[(1) - (1)].lex).line);
         else
             (yyval.interm.type).setBasic(EbtVoid, EvqVaryingIn, (yyvsp[(1) - (1)].lex).line);
-    ;}
+    }
     break;
 
   case 107:
 
     {
         if (context->globalErrorCheck((yyvsp[(1) - (2)].lex).line, context->symbolTable.atGlobalLevel(), "invariant varying"))
             context->recover();
         if (context->shaderType == SH_VERTEX_SHADER)
             (yyval.interm.type).setBasic(EbtVoid, EvqInvariantVaryingOut, (yyvsp[(1) - (2)].lex).line);
         else
             (yyval.interm.type).setBasic(EbtVoid, EvqInvariantVaryingIn, (yyvsp[(1) - (2)].lex).line);
-    ;}
+    }
     break;
 
   case 108:
 
     {
         if (context->globalErrorCheck((yyvsp[(1) - (1)].lex).line, context->symbolTable.atGlobalLevel(), "uniform"))
             context->recover();
         (yyval.interm.type).setBasic(EbtVoid, EvqUniform, (yyvsp[(1) - (1)].lex).line);
-    ;}
+    }
     break;
 
   case 109:
 
     {
         (yyval.interm.type) = (yyvsp[(1) - (1)].interm.type);
 
         if ((yyval.interm.type).precision == EbpUndefined) {
             (yyval.interm.type).precision = context->symbolTable.getDefaultPrecision((yyvsp[(1) - (1)].interm.type).type);
             if (context->precisionErrorCheck((yyvsp[(1) - (1)].interm.type).line, (yyval.interm.type).precision, (yyvsp[(1) - (1)].interm.type).type)) {
                 context->recover();
             }
         }
-    ;}
+    }
     break;
 
   case 110:
 
     {
         (yyval.interm.type) = (yyvsp[(2) - (2)].interm.type);
         (yyval.interm.type).precision = (yyvsp[(1) - (2)].interm.precision);
-    ;}
+    }
     break;
 
   case 111:
 
     {
         (yyval.interm.precision) = EbpHigh;
-    ;}
+    }
     break;
 
   case 112:
 
     {
         (yyval.interm.precision) = EbpMedium;
-    ;}
+    }
     break;
 
   case 113:
 
     {
         (yyval.interm.precision) = EbpLow;
-    ;}
+    }
     break;
 
   case 114:
 
     {
         (yyval.interm.type) = (yyvsp[(1) - (1)].interm.type);
-    ;}
+    }
     break;
 
   case 115:
 
     {
         (yyval.interm.type) = (yyvsp[(1) - (4)].interm.type);
 
         if (context->arrayTypeErrorCheck((yyvsp[(2) - (4)].lex).line, (yyvsp[(1) - (4)].interm.type)))
             context->recover();
         else {
             int size;
             if (context->arraySizeErrorCheck((yyvsp[(2) - (4)].lex).line, (yyvsp[(3) - (4)].interm.intermTypedNode), size))
                 context->recover();
             (yyval.interm.type).setArray(true, size);
         }
-    ;}
+    }
     break;
 
   case 116:
 
     {
         TQualifier qual = context->symbolTable.atGlobalLevel() ? EvqGlobal : EvqTemporary;
         (yyval.interm.type).setBasic(EbtVoid, qual, (yyvsp[(1) - (1)].lex).line);
-    ;}
+    }
     break;
 
   case 117:
 
     {
         TQualifier qual = context->symbolTable.atGlobalLevel() ? EvqGlobal : EvqTemporary;
         (yyval.interm.type).setBasic(EbtFloat, qual, (yyvsp[(1) - (1)].lex).line);
-    ;}
+    }
     break;
 
   case 118:
 
     {
         TQualifier qual = context->symbolTable.atGlobalLevel() ? EvqGlobal : EvqTemporary;
         (yyval.interm.type).setBasic(EbtInt, qual, (yyvsp[(1) - (1)].lex).line);
-    ;}
+    }
     break;
 
   case 119:
 
     {
         TQualifier qual = context->symbolTable.atGlobalLevel() ? EvqGlobal : EvqTemporary;
         (yyval.interm.type).setBasic(EbtBool, qual, (yyvsp[(1) - (1)].lex).line);
-    ;}
+    }
     break;
 
   case 120:
 
     {
         TQualifier qual = context->symbolTable.atGlobalLevel() ? EvqGlobal : EvqTemporary;
         (yyval.interm.type).setBasic(EbtFloat, qual, (yyvsp[(1) - (1)].lex).line);
         (yyval.interm.type).setAggregate(2);
-    ;}
+    }
     break;
 
   case 121:
 
     {
         TQualifier qual = context->symbolTable.atGlobalLevel() ? EvqGlobal : EvqTemporary;
         (yyval.interm.type).setBasic(EbtFloat, qual, (yyvsp[(1) - (1)].lex).line);
         (yyval.interm.type).setAggregate(3);
-    ;}
+    }
     break;
 
   case 122:
 
     {
         TQualifier qual = context->symbolTable.atGlobalLevel() ? EvqGlobal : EvqTemporary;
         (yyval.interm.type).setBasic(EbtFloat, qual, (yyvsp[(1) - (1)].lex).line);
         (yyval.interm.type).setAggregate(4);
-    ;}
+    }
     break;
 
   case 123:
 
     {
         TQualifier qual = context->symbolTable.atGlobalLevel() ? EvqGlobal : EvqTemporary;
         (yyval.interm.type).setBasic(EbtBool, qual, (yyvsp[(1) - (1)].lex).line);
         (yyval.interm.type).setAggregate(2);
-    ;}
+    }
     break;
 
   case 124:
 
     {
         TQualifier qual = context->symbolTable.atGlobalLevel() ? EvqGlobal : EvqTemporary;
         (yyval.interm.type).setBasic(EbtBool, qual, (yyvsp[(1) - (1)].lex).line);
         (yyval.interm.type).setAggregate(3);
-    ;}
+    }
     break;
 
   case 125:
 
     {
         TQualifier qual = context->symbolTable.atGlobalLevel() ? EvqGlobal : EvqTemporary;
         (yyval.interm.type).setBasic(EbtBool, qual, (yyvsp[(1) - (1)].lex).line);
         (yyval.interm.type).setAggregate(4);
-    ;}
+    }
     break;
 
   case 126:
 
     {
         TQualifier qual = context->symbolTable.atGlobalLevel() ? EvqGlobal : EvqTemporary;
         (yyval.interm.type).setBasic(EbtInt, qual, (yyvsp[(1) - (1)].lex).line);
         (yyval.interm.type).setAggregate(2);
-    ;}
+    }
     break;
 
   case 127:
 
     {
         TQualifier qual = context->symbolTable.atGlobalLevel() ? EvqGlobal : EvqTemporary;
         (yyval.interm.type).setBasic(EbtInt, qual, (yyvsp[(1) - (1)].lex).line);
         (yyval.interm.type).setAggregate(3);
-    ;}
+    }
     break;
 
   case 128:
 
     {
         TQualifier qual = context->symbolTable.atGlobalLevel() ? EvqGlobal : EvqTemporary;
         (yyval.interm.type).setBasic(EbtInt, qual, (yyvsp[(1) - (1)].lex).line);
         (yyval.interm.type).setAggregate(4);
-    ;}
+    }
     break;
 
   case 129:
 
     {
         FRAG_VERT_ONLY("mat2", (yyvsp[(1) - (1)].lex).line);
         TQualifier qual = context->symbolTable.atGlobalLevel() ? EvqGlobal : EvqTemporary;
         (yyval.interm.type).setBasic(EbtFloat, qual, (yyvsp[(1) - (1)].lex).line);
         (yyval.interm.type).setAggregate(2, true);
-    ;}
+    }
     break;
 
   case 130:
 
     {
         FRAG_VERT_ONLY("mat3", (yyvsp[(1) - (1)].lex).line);
         TQualifier qual = context->symbolTable.atGlobalLevel() ? EvqGlobal : EvqTemporary;
         (yyval.interm.type).setBasic(EbtFloat, qual, (yyvsp[(1) - (1)].lex).line);
         (yyval.interm.type).setAggregate(3, true);
-    ;}
+    }
     break;
 
   case 131:
 
     {
         FRAG_VERT_ONLY("mat4", (yyvsp[(1) - (1)].lex).line);
         TQualifier qual = context->symbolTable.atGlobalLevel() ? EvqGlobal : EvqTemporary;
         (yyval.interm.type).setBasic(EbtFloat, qual, (yyvsp[(1) - (1)].lex).line);
         (yyval.interm.type).setAggregate(4, true);
-    ;}
+    }
     break;
 
   case 132:
 
     {
         FRAG_VERT_ONLY("sampler2D", (yyvsp[(1) - (1)].lex).line);
         TQualifier qual = context->symbolTable.atGlobalLevel() ? EvqGlobal : EvqTemporary;
         (yyval.interm.type).setBasic(EbtSampler2D, qual, (yyvsp[(1) - (1)].lex).line);
-    ;}
+    }
     break;
 
   case 133:
 
     {
         FRAG_VERT_ONLY("samplerCube", (yyvsp[(1) - (1)].lex).line);
         TQualifier qual = context->symbolTable.atGlobalLevel() ? EvqGlobal : EvqTemporary;
         (yyval.interm.type).setBasic(EbtSamplerCube, qual, (yyvsp[(1) - (1)].lex).line);
-    ;}
+    }
     break;
 
   case 134:
 
     {
         if (!context->supportsExtension("GL_OES_EGL_image_external")) {
             context->error((yyvsp[(1) - (1)].lex).line, "unsupported type", "samplerExternalOES", "");
             context->recover();
         }
         FRAG_VERT_ONLY("samplerExternalOES", (yyvsp[(1) - (1)].lex).line);
         TQualifier qual = context->symbolTable.atGlobalLevel() ? EvqGlobal : EvqTemporary;
         (yyval.interm.type).setBasic(EbtSamplerExternalOES, qual, (yyvsp[(1) - (1)].lex).line);
-    ;}
+    }
     break;
 
   case 135:
 
     {
+        if (!context->supportsExtension("GL_ARB_texture_rectangle")) {
+            context->error((yyvsp[(1) - (1)].lex).line, "unsupported type", "sampler2DRect", "");
+            context->recover();
+        }
+        FRAG_VERT_ONLY("sampler2DRect", (yyvsp[(1) - (1)].lex).line);
+        TQualifier qual = context->symbolTable.atGlobalLevel() ? EvqGlobal : EvqTemporary;
+        (yyval.interm.type).setBasic(EbtSampler2DRect, qual, (yyvsp[(1) - (1)].lex).line);
+    }
+    break;
+
+  case 136:
+
+    {
         FRAG_VERT_ONLY("struct", (yyvsp[(1) - (1)].interm.type).line);
         (yyval.interm.type) = (yyvsp[(1) - (1)].interm.type);
         (yyval.interm.type).qualifier = context->symbolTable.atGlobalLevel() ? EvqGlobal : EvqTemporary;
-    ;}
+    }
     break;
 
-  case 136:
+  case 137:
 
     {
         //
         // This is for user defined type names.  The lexical phase looked up the
         // type.
         //
         TType& structure = static_cast<TVariable*>((yyvsp[(1) - (1)].lex).symbol)->getType();
         TQualifier qual = context->symbolTable.atGlobalLevel() ? EvqGlobal : EvqTemporary;
         (yyval.interm.type).setBasic(EbtStruct, qual, (yyvsp[(1) - (1)].lex).line);
         (yyval.interm.type).userDef = &structure;
-    ;}
-    break;
-
-  case 137:
-
-    { if (context->enterStructDeclaration((yyvsp[(2) - (3)].lex).line, *(yyvsp[(2) - (3)].lex).string)) context->recover(); ;}
+    }
     break;
 
   case 138:
 
+    { if (context->enterStructDeclaration((yyvsp[(2) - (3)].lex).line, *(yyvsp[(2) - (3)].lex).string)) context->recover(); }
+    break;
+
+  case 139:
+
     {
         if (context->reservedErrorCheck((yyvsp[(2) - (6)].lex).line, *(yyvsp[(2) - (6)].lex).string))
             context->recover();
 
         TType* structure = new TType((yyvsp[(5) - (6)].interm.typeList), *(yyvsp[(2) - (6)].lex).string);
         TVariable* userTypeDef = new TVariable((yyvsp[(2) - (6)].lex).string, *structure, true);
         if (! context->symbolTable.insert(*userTypeDef)) {
             context->error((yyvsp[(2) - (6)].lex).line, "redefinition", (yyvsp[(2) - (6)].lex).string->c_str(), "struct");
             context->recover();
         }
         (yyval.interm.type).setBasic(EbtStruct, EvqTemporary, (yyvsp[(1) - (6)].lex).line);
         (yyval.interm.type).userDef = structure;
         context->exitStructDeclaration();
-    ;}
-    break;
-
-  case 139:
-
-    { if (context->enterStructDeclaration((yyvsp[(2) - (2)].lex).line, *(yyvsp[(2) - (2)].lex).string)) context->recover(); ;}
+    }
     break;
 
   case 140:
 
+    { if (context->enterStructDeclaration((yyvsp[(2) - (2)].lex).line, *(yyvsp[(2) - (2)].lex).string)) context->recover(); }
+    break;
+
+  case 141:
+
     {
         TType* structure = new TType((yyvsp[(4) - (5)].interm.typeList), TString(""));
         (yyval.interm.type).setBasic(EbtStruct, EvqTemporary, (yyvsp[(1) - (5)].lex).line);
         (yyval.interm.type).userDef = structure;
         context->exitStructDeclaration();
-    ;}
+    }
     break;
 
-  case 141:
+  case 142:
 
     {
         (yyval.interm.typeList) = (yyvsp[(1) - (1)].interm.typeList);
-    ;}
+    }
     break;
 
-  case 142:
+  case 143:
 
     {
         (yyval.interm.typeList) = (yyvsp[(1) - (2)].interm.typeList);
         for (unsigned int i = 0; i < (yyvsp[(2) - (2)].interm.typeList)->size(); ++i) {
             for (unsigned int j = 0; j < (yyval.interm.typeList)->size(); ++j) {
                 if ((*(yyval.interm.typeList))[j].type->getFieldName() == (*(yyvsp[(2) - (2)].interm.typeList))[i].type->getFieldName()) {
                     context->error((*(yyvsp[(2) - (2)].interm.typeList))[i].line, "duplicate field name in structure:", "struct", (*(yyvsp[(2) - (2)].interm.typeList))[i].type->getFieldName().c_str());
                     context->recover();
                 }
             }
             (yyval.interm.typeList)->push_back((*(yyvsp[(2) - (2)].interm.typeList))[i]);
         }
-    ;}
+    }
     break;
 
-  case 143:
+  case 144:
 
     {
         (yyval.interm.typeList) = (yyvsp[(2) - (3)].interm.typeList);
 
         if (context->voidErrorCheck((yyvsp[(1) - (3)].interm.type).line, (*(yyvsp[(2) - (3)].interm.typeList))[0].type->getFieldName(), (yyvsp[(1) - (3)].interm.type))) {
             context->recover();
         }
         for (unsigned int i = 0; i < (yyval.interm.typeList)->size(); ++i) {
@@ -4001,415 +3934,415 @@ yyreduce:
                 type->setStruct((yyvsp[(1) - (3)].interm.type).userDef->getStruct());
                 type->setTypeName((yyvsp[(1) - (3)].interm.type).userDef->getTypeName());
             }
 
             if (context->structNestingErrorCheck((yyvsp[(1) - (3)].interm.type).line, *type)) {
                 context->recover();
             }
         }
-    ;}
-    break;
-
-  case 144:
-
-    {
-        (yyval.interm.typeList) = NewPoolTTypeList();
-        (yyval.interm.typeList)->push_back((yyvsp[(1) - (1)].interm.typeLine));
-    ;}
+    }
     break;
 
   case 145:
 
     {
-        (yyval.interm.typeList)->push_back((yyvsp[(3) - (3)].interm.typeLine));
-    ;}
+        (yyval.interm.typeList) = NewPoolTTypeList();
+        (yyval.interm.typeList)->push_back((yyvsp[(1) - (1)].interm.typeLine));
+    }
     break;
 
   case 146:
 
     {
+        (yyval.interm.typeList)->push_back((yyvsp[(3) - (3)].interm.typeLine));
+    }
+    break;
+
+  case 147:
+
+    {
         if (context->reservedErrorCheck((yyvsp[(1) - (1)].lex).line, *(yyvsp[(1) - (1)].lex).string))
             context->recover();
 
         (yyval.interm.typeLine).type = new TType(EbtVoid, EbpUndefined);
         (yyval.interm.typeLine).line = (yyvsp[(1) - (1)].lex).line;
         (yyval.interm.typeLine).type->setFieldName(*(yyvsp[(1) - (1)].lex).string);
-    ;}
+    }
     break;
 
-  case 147:
+  case 148:
 
     {
         if (context->reservedErrorCheck((yyvsp[(1) - (4)].lex).line, *(yyvsp[(1) - (4)].lex).string))
             context->recover();
 
         (yyval.interm.typeLine).type = new TType(EbtVoid, EbpUndefined);
         (yyval.interm.typeLine).line = (yyvsp[(1) - (4)].lex).line;
         (yyval.interm.typeLine).type->setFieldName(*(yyvsp[(1) - (4)].lex).string);
 
         int size;
         if (context->arraySizeErrorCheck((yyvsp[(2) - (4)].lex).line, (yyvsp[(3) - (4)].interm.intermTypedNode), size))
             context->recover();
         (yyval.interm.typeLine).type->setArraySize(size);
-    ;}
-    break;
-
-  case 148:
-
-    { (yyval.interm.intermTypedNode) = (yyvsp[(1) - (1)].interm.intermTypedNode); ;}
+    }
     break;
 
   case 149:
 
-    { (yyval.interm.intermNode) = (yyvsp[(1) - (1)].interm.intermNode); ;}
+    { (yyval.interm.intermTypedNode) = (yyvsp[(1) - (1)].interm.intermTypedNode); }
     break;
 
   case 150:
 
-    { (yyval.interm.intermNode) = (yyvsp[(1) - (1)].interm.intermAggregate); ;}
+    { (yyval.interm.intermNode) = (yyvsp[(1) - (1)].interm.intermNode); }
     break;
 
   case 151:
 
-    { (yyval.interm.intermNode) = (yyvsp[(1) - (1)].interm.intermNode); ;}
+    { (yyval.interm.intermNode) = (yyvsp[(1) - (1)].interm.intermAggregate); }
     break;
 
   case 152:
 
-    { (yyval.interm.intermNode) = (yyvsp[(1) - (1)].interm.intermNode); ;}
+    { (yyval.interm.intermNode) = (yyvsp[(1) - (1)].interm.intermNode); }
     break;
 
   case 153:
 
-    { (yyval.interm.intermNode) = (yyvsp[(1) - (1)].interm.intermNode); ;}
+    { (yyval.interm.intermNode) = (yyvsp[(1) - (1)].interm.intermNode); }
     break;
 
   case 154:
 
-    { (yyval.interm.intermNode) = (yyvsp[(1) - (1)].interm.intermNode); ;}
+    { (yyval.interm.intermNode) = (yyvsp[(1) - (1)].interm.intermNode); }
     break;
 
   case 155:
 
-    { (yyval.interm.intermNode) = (yyvsp[(1) - (1)].interm.intermNode); ;}
+    { (yyval.interm.intermNode) = (yyvsp[(1) - (1)].interm.intermNode); }
     break;
 
   case 156:
 
-    { (yyval.interm.intermNode) = (yyvsp[(1) - (1)].interm.intermNode); ;}
+    { (yyval.interm.intermNode) = (yyvsp[(1) - (1)].interm.intermNode); }
     break;
 
   case 157:
 
-    { (yyval.interm.intermAggregate) = 0; ;}
+    { (yyval.interm.intermNode) = (yyvsp[(1) - (1)].interm.intermNode); }
     break;
 
   case 158:
 
-    { context->symbolTable.push(); ;}
+    { (yyval.interm.intermAggregate) = 0; }
     break;
 
   case 159:
 
-    { context->symbolTable.pop(); ;}
+    { context->symbolTable.push(); }
     break;
 
   case 160:
 
+    { context->symbolTable.pop(); }
+    break;
+
+  case 161:
+
     {
         if ((yyvsp[(3) - (5)].interm.intermAggregate) != 0) {
             (yyvsp[(3) - (5)].interm.intermAggregate)->setOp(EOpSequence);
             (yyvsp[(3) - (5)].interm.intermAggregate)->setEndLine((yyvsp[(5) - (5)].lex).line);
         }
         (yyval.interm.intermAggregate) = (yyvsp[(3) - (5)].interm.intermAggregate);
-    ;}
-    break;
-
-  case 161:
-
-    { (yyval.interm.intermNode) = (yyvsp[(1) - (1)].interm.intermNode); ;}
+    }
     break;
 
   case 162:
 
-    { (yyval.interm.intermNode) = (yyvsp[(1) - (1)].interm.intermNode); ;}
+    { (yyval.interm.intermNode) = (yyvsp[(1) - (1)].interm.intermNode); }
     break;
 
   case 163:
 
-    {
-        (yyval.interm.intermNode) = 0;
-    ;}
+    { (yyval.interm.intermNode) = (yyvsp[(1) - (1)].interm.intermNode); }
     break;
 
   case 164:
 
     {
+        (yyval.interm.intermNode) = 0;
+    }
+    break;
+
+  case 165:
+
+    {
         if ((yyvsp[(2) - (3)].interm.intermAggregate)) {
             (yyvsp[(2) - (3)].interm.intermAggregate)->setOp(EOpSequence);
             (yyvsp[(2) - (3)].interm.intermAggregate)->setEndLine((yyvsp[(3) - (3)].lex).line);
         }
         (yyval.interm.intermNode) = (yyvsp[(2) - (3)].interm.intermAggregate);
-    ;}
-    break;
-
-  case 165:
-
-    {
-        (yyval.interm.intermAggregate) = context->intermediate.makeAggregate((yyvsp[(1) - (1)].interm.intermNode), 0);
-    ;}
+    }
     break;
 
   case 166:
 
     {
-        (yyval.interm.intermAggregate) = context->intermediate.growAggregate((yyvsp[(1) - (2)].interm.intermAggregate), (yyvsp[(2) - (2)].interm.intermNode), 0);
-    ;}
+        (yyval.interm.intermAggregate) = context->intermediate.makeAggregate((yyvsp[(1) - (1)].interm.intermNode), 0);
+    }
     break;
 
   case 167:
 
-    { (yyval.interm.intermNode) = 0; ;}
+    {
+        (yyval.interm.intermAggregate) = context->intermediate.growAggregate((yyvsp[(1) - (2)].interm.intermAggregate), (yyvsp[(2) - (2)].interm.intermNode), 0);
+    }
     break;
 
   case 168:
 
-    { (yyval.interm.intermNode) = static_cast<TIntermNode*>((yyvsp[(1) - (2)].interm.intermTypedNode)); ;}
+    { (yyval.interm.intermNode) = 0; }
     break;
 
   case 169:
 
+    { (yyval.interm.intermNode) = static_cast<TIntermNode*>((yyvsp[(1) - (2)].interm.intermTypedNode)); }
+    break;
+
+  case 170:
+
     {
         if (context->boolErrorCheck((yyvsp[(1) - (5)].lex).line, (yyvsp[(3) - (5)].interm.intermTypedNode)))
             context->recover();
         (yyval.interm.intermNode) = context->intermediate.addSelection((yyvsp[(3) - (5)].interm.intermTypedNode), (yyvsp[(5) - (5)].interm.nodePair), (yyvsp[(1) - (5)].lex).line);
-    ;}
-    break;
-
-  case 170:
-
-    {
-        (yyval.interm.nodePair).node1 = (yyvsp[(1) - (3)].interm.intermNode);
-        (yyval.interm.nodePair).node2 = (yyvsp[(3) - (3)].interm.intermNode);
-    ;}
+    }
     break;
 
   case 171:
 
     {
-        (yyval.interm.nodePair).node1 = (yyvsp[(1) - (1)].interm.intermNode);
-        (yyval.interm.nodePair).node2 = 0;
-    ;}
+        (yyval.interm.nodePair).node1 = (yyvsp[(1) - (3)].interm.intermNode);
+        (yyval.interm.nodePair).node2 = (yyvsp[(3) - (3)].interm.intermNode);
+    }
     break;
 
   case 172:
 
     {
+        (yyval.interm.nodePair).node1 = (yyvsp[(1) - (1)].interm.intermNode);
+        (yyval.interm.nodePair).node2 = 0;
+    }
+    break;
+
+  case 173:
+
+    {
         (yyval.interm.intermTypedNode) = (yyvsp[(1) - (1)].interm.intermTypedNode);
         if (context->boolErrorCheck((yyvsp[(1) - (1)].interm.intermTypedNode)->getLine(), (yyvsp[(1) - (1)].interm.intermTypedNode)))
             context->recover();
-    ;}
+    }
     break;
 
-  case 173:
+  case 174:
 
     {
         TIntermNode* intermNode;
         if (context->structQualifierErrorCheck((yyvsp[(2) - (4)].lex).line, (yyvsp[(1) - (4)].interm.type)))
             context->recover();
         if (context->boolErrorCheck((yyvsp[(2) - (4)].lex).line, (yyvsp[(1) - (4)].interm.type)))
             context->recover();
 
         if (!context->executeInitializer((yyvsp[(2) - (4)].lex).line, *(yyvsp[(2) - (4)].lex).string, (yyvsp[(1) - (4)].interm.type), (yyvsp[(4) - (4)].interm.intermTypedNode), intermNode))
             (yyval.interm.intermTypedNode) = (yyvsp[(4) - (4)].interm.intermTypedNode);
         else {
             context->recover();
             (yyval.interm.intermTypedNode) = 0;
         }
-    ;}
-    break;
-
-  case 174:
-
-    { context->symbolTable.push(); ++context->loopNestingLevel; ;}
+    }
     break;
 
   case 175:
 
+    { context->symbolTable.push(); ++context->loopNestingLevel; }
+    break;
+
+  case 176:
+
     {
         context->symbolTable.pop();
         (yyval.interm.intermNode) = context->intermediate.addLoop(ELoopWhile, 0, (yyvsp[(4) - (6)].interm.intermTypedNode), 0, (yyvsp[(6) - (6)].interm.intermNode), (yyvsp[(1) - (6)].lex).line);
         --context->loopNestingLevel;
-    ;}
-    break;
-
-  case 176:
-
-    { ++context->loopNestingLevel; ;}
+    }
     break;
 
   case 177:
 
+    { ++context->loopNestingLevel; }
+    break;
+
+  case 178:
+
     {
         if (context->boolErrorCheck((yyvsp[(8) - (8)].lex).line, (yyvsp[(6) - (8)].interm.intermTypedNode)))
             context->recover();
 
         (yyval.interm.intermNode) = context->intermediate.addLoop(ELoopDoWhile, 0, (yyvsp[(6) - (8)].interm.intermTypedNode), 0, (yyvsp[(3) - (8)].interm.intermNode), (yyvsp[(4) - (8)].lex).line);
         --context->loopNestingLevel;
-    ;}
-    break;
-
-  case 178:
-
-    { context->symbolTable.push(); ++context->loopNestingLevel; ;}
+    }
     break;
 
   case 179:
 
+    { context->symbolTable.push(); ++context->loopNestingLevel; }
+    break;
+
+  case 180:
+
     {
         context->symbolTable.pop();
         (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), (yyvsp[(1) - (7)].lex).line);
         --context->loopNestingLevel;
-    ;}
-    break;
-
-  case 180:
-
-    {
-        (yyval.interm.intermNode) = (yyvsp[(1) - (1)].interm.intermNode);
-    ;}
+    }
     break;
 
   case 181:
 
     {
         (yyval.interm.intermNode) = (yyvsp[(1) - (1)].interm.intermNode);
-    ;}
+    }
     break;
 
   case 182:
 
     {
-        (yyval.interm.intermTypedNode) = (yyvsp[(1) - (1)].interm.intermTypedNode);
-    ;}
+        (yyval.interm.intermNode) = (yyvsp[(1) - (1)].interm.intermNode);
+    }
     break;
 
   case 183:
 
     {
-        (yyval.interm.intermTypedNode) = 0;
-    ;}
+        (yyval.interm.intermTypedNode) = (yyvsp[(1) - (1)].interm.intermTypedNode);
+    }
     break;
 
   case 184:
 
     {
-        (yyval.interm.nodePair).node1 = (yyvsp[(1) - (2)].interm.intermTypedNode);
-        (yyval.interm.nodePair).node2 = 0;
-    ;}
+        (yyval.interm.intermTypedNode) = 0;
+    }
     break;
 
   case 185:
 
     {
-        (yyval.interm.nodePair).node1 = (yyvsp[(1) - (3)].interm.intermTypedNode);
-        (yyval.interm.nodePair).node2 = (yyvsp[(3) - (3)].interm.intermTypedNode);
-    ;}
+        (yyval.interm.nodePair).node1 = (yyvsp[(1) - (2)].interm.intermTypedNode);
+        (yyval.interm.nodePair).node2 = 0;
+    }
     break;
 
   case 186:
 
     {
+        (yyval.interm.nodePair).node1 = (yyvsp[(1) - (3)].interm.intermTypedNode);
+        (yyval.interm.nodePair).node2 = (yyvsp[(3) - (3)].interm.intermTypedNode);
+    }
+    break;
+
+  case 187:
+
+    {
         if (context->loopNestingLevel <= 0) {
             context->error((yyvsp[(1) - (2)].lex).line, "continue statement only allowed in loops", "", "");
             context->recover();
         }
         (yyval.interm.intermNode) = context->intermediate.addBranch(EOpContinue, (yyvsp[(1) - (2)].lex).line);
-    ;}
+    }
     break;
 
-  case 187:
+  case 188:
 
     {
         if (context->loopNestingLevel <= 0) {
             context->error((yyvsp[(1) - (2)].lex).line, "break statement only allowed in loops", "", "");
             context->recover();
         }
         (yyval.interm.intermNode) = context->intermediate.addBranch(EOpBreak, (yyvsp[(1) - (2)].lex).line);
-    ;}
+    }
     break;
 
-  case 188:
+  case 189:
 
     {
         (yyval.interm.intermNode) = context->intermediate.addBranch(EOpReturn, (yyvsp[(1) - (2)].lex).line);
         if (context->currentFunctionType->getBasicType() != EbtVoid) {
             context->error((yyvsp[(1) - (2)].lex).line, "non-void function must return a value", "return", "");
             context->recover();
         }
-    ;}
+    }
     break;
 
-  case 189:
+  case 190:
 
     {
         (yyval.interm.intermNode) = context->intermediate.addBranch(EOpReturn, (yyvsp[(2) - (3)].interm.intermTypedNode), (yyvsp[(1) - (3)].lex).line);
         context->functionReturnsValue = true;
         if (context->currentFunctionType->getBasicType() == EbtVoid) {
             context->error((yyvsp[(1) - (3)].lex).line, "void function cannot return a value", "return", "");
             context->recover();
         } else if (*(context->currentFunctionType) != (yyvsp[(2) - (3)].interm.intermTypedNode)->getType()) {
             context->error((yyvsp[(1) - (3)].lex).line, "function return is not matching type:", "return", "");
             context->recover();
         }
-    ;}
-    break;
-
-  case 190:
-
-    {
-        FRAG_ONLY("discard", (yyvsp[(1) - (2)].lex).line);
-        (yyval.interm.intermNode) = context->intermediate.addBranch(EOpKill, (yyvsp[(1) - (2)].lex).line);
-    ;}
+    }
     break;
 
   case 191:
 
     {
-        (yyval.interm.intermNode) = (yyvsp[(1) - (1)].interm.intermNode);
-        context->treeRoot = (yyval.interm.intermNode);
-    ;}
+        FRAG_ONLY("discard", (yyvsp[(1) - (2)].lex).line);
+        (yyval.interm.intermNode) = context->intermediate.addBranch(EOpKill, (yyvsp[(1) - (2)].lex).line);
+    }
     break;
 
   case 192:
 
     {
-        (yyval.interm.intermNode) = context->intermediate.growAggregate((yyvsp[(1) - (2)].interm.intermNode), (yyvsp[(2) - (2)].interm.intermNode), 0);
+        (yyval.interm.intermNode) = (yyvsp[(1) - (1)].interm.intermNode);
         context->treeRoot = (yyval.interm.intermNode);
-    ;}
+    }
     break;
 
   case 193:
 
     {
-        (yyval.interm.intermNode) = (yyvsp[(1) - (1)].interm.intermNode);
-    ;}
+        (yyval.interm.intermNode) = context->intermediate.growAggregate((yyvsp[(1) - (2)].interm.intermNode), (yyvsp[(2) - (2)].interm.intermNode), 0);
+        context->treeRoot = (yyval.interm.intermNode);
+    }
     break;
 
   case 194:
 
     {
         (yyval.interm.intermNode) = (yyvsp[(1) - (1)].interm.intermNode);
-    ;}
+    }
     break;
 
   case 195:
 
     {
+        (yyval.interm.intermNode) = (yyvsp[(1) - (1)].interm.intermNode);
+    }
+    break;
+
+  case 196:
+
+    {
         TFunction* function = (yyvsp[(1) - (1)].interm).function;
         TFunction* prevDec = static_cast<TFunction*>(context->symbolTable.find(function->getMangledName()));
         //
         // Note:  'prevDec' could be 'function' if this is the first time we've seen function
         // as it would have just been put in the symbol table.  Otherwise, we're looking up
         // an earlier occurance.
         //
         if (prevDec->isDefined()) {
@@ -4479,20 +4412,20 @@ yyreduce:
                                                (yyvsp[(1) - (1)].interm).line);
             } else {
                 paramNodes = context->intermediate.growAggregate(paramNodes, context->intermediate.addSymbol(0, "", *param.type, (yyvsp[(1) - (1)].interm).line), (yyvsp[(1) - (1)].interm).line);
             }
         }
         context->intermediate.setAggregateOperator(paramNodes, EOpParameters, (yyvsp[(1) - (1)].interm).line);
         (yyvsp[(1) - (1)].interm).intermAggregate = paramNodes;
         context->loopNestingLevel = 0;
-    ;}
+    }
     break;
 
-  case 196:
+  case 197:
 
     {
         //?? Check that all paths return a value if return type != void ?
         //   May be best done as post process phase on intermediate code
         if (context->currentFunctionType->getBasicType() != EbtVoid && ! context->functionReturnsValue) {
             context->error((yyvsp[(1) - (3)].interm).line, "function does not return a value:", "", (yyvsp[(1) - (3)].interm).function->getName().c_str());
             context->recover();
         }
@@ -4505,33 +4438,31 @@ yyreduce:
         // store the pragma information for debug and optimize and other vendor specific
         // information. This information can be queried from the parse tree
         (yyval.interm.intermNode)->getAsAggregate()->setOptimize(context->contextPragma.optimize);
         (yyval.interm.intermNode)->getAsAggregate()->setDebug(context->contextPragma.debug);
         (yyval.interm.intermNode)->getAsAggregate()->addToPragmaTable(context->contextPragma.pragmaTable);
 
         if ((yyvsp[(3) - (3)].interm.intermNode) && (yyvsp[(3) - (3)].interm.intermNode)->getAsAggregate())
             (yyval.interm.intermNode)->getAsAggregate()->setEndLine((yyvsp[(3) - (3)].interm.intermNode)->getAsAggregate()->getEndLine());
-    ;}
+    }
     break;
 
 
-/* Line 1267 of yacc.c.  */
 
       default: break;
     }
   YY_SYMBOL_PRINT ("-> $$ =", yyr1[yyn], &yyval, &yyloc);
 
   YYPOPSTACK (yylen);
   yylen = 0;
   YY_STACK_PRINT (yyss, yyssp);
 
   *++yyvsp = yyval;
 
-
   /* Now `shift' the result of the reduction.  Determine what state
      that goes to, based on the state we popped back to and the rule
      number reduced by.  */
 
   yyn = yyr1[yyn];
 
   yystate = yypgoto[yyn - YYNTOKENS] + *yyssp;
   if (0 <= yystate && yystate <= YYLAST && yycheck[yystate] == *yyssp)
@@ -4586,34 +4517,34 @@ yyerrlab:
       }
 #endif
     }
 
 
 
   if (yyerrstatus == 3)
     {
-      /* If just tried and failed to reuse look-ahead token after an
+      /* If just tried and failed to reuse lookahead token after an
 	 error, discard it.  */
 
       if (yychar <= YYEOF)
 	{
 	  /* Return failure if at end of input.  */
 	  if (yychar == YYEOF)
 	    YYABORT;
 	}
       else
 	{
 	  yydestruct ("Error: discarding",
 		      yytoken, &yylval, context);
 	  yychar = YYEMPTY;
 	}
     }
 
-  /* Else will try to reuse look-ahead token after shifting the error
+  /* Else will try to reuse lookahead token after shifting the error
      token.  */
   goto yyerrlab1;
 
 
 /*---------------------------------------------------.
 | yyerrorlab -- error raised explicitly by YYERROR.  |
 `---------------------------------------------------*/
 yyerrorlab:
@@ -4660,19 +4591,16 @@ yyerrlab1:
 
       yydestruct ("Error: popping",
 		  yystos[yystate], yyvsp, context);
       YYPOPSTACK (1);
       yystate = *yyssp;
       YY_STACK_PRINT (yyss, yyssp);
     }
 
-  if (yyn == YYFINAL)
-    YYACCEPT;
-
   *++yyvsp = yylval;
 
 
   /* Shift the error token.  */
   YY_SYMBOL_PRINT ("Shifting", yystos[yyn], yyvsp, yylsp);
 
   yystate = yyn;
   goto yynewstate;
@@ -4687,28 +4615,28 @@ yyacceptlab:
 
 /*-----------------------------------.
 | yyabortlab -- YYABORT comes here.  |
 `-----------------------------------*/
 yyabortlab:
   yyresult = 1;
   goto yyreturn;
 
-#ifndef yyoverflow
+#if !defined(yyoverflow) || YYERROR_VERBOSE
 /*-------------------------------------------------.
 | yyexhaustedlab -- memory exhaustion comes here.  |
 `-------------------------------------------------*/
 yyexhaustedlab:
   yyerror (context, YY_("memory exhausted"));
   yyresult = 2;
   /* Fall through.  */
 #endif
 
 yyreturn:
-  if (yychar != YYEOF && yychar != YYEMPTY)
+  if (yychar != YYEMPTY)
      yydestruct ("Cleanup: discarding lookahead",
 		 yytoken, &yylval, context);
   /* Do not reclaim the symbols of the rule which action triggered
      this YYABORT or YYACCEPT.  */
   YYPOPSTACK (yylen);
   YY_STACK_PRINT (yyss, yyssp);
   while (yyssp != yyss)
     {
--- a/gfx/angle/src/compiler/glslang_tab.h
+++ b/gfx/angle/src/compiler/glslang_tab.h
@@ -1,43 +1,43 @@
-/* A Bison parser, made by GNU Bison 2.3.  */
+
+/* A Bison parser, made by GNU Bison 2.4.1.  */
 
 /* Skeleton interface for Bison's Yacc-like parsers in C
-
-   Copyright (C) 1984, 1989, 1990, 2000, 2001, 2002, 2003, 2004, 2005, 2006
+   
+      Copyright (C) 1984, 1989, 1990, 2000, 2001, 2002, 2003, 2004, 2005, 2006
    Free Software Foundation, Inc.
-
-   This program is free software; you can redistribute it and/or modify
+   
+   This program is free software: you can redistribute it and/or modify
    it under the terms of the GNU General Public License as published by
-   the Free Software Foundation; either version 2, or (at your option)
-   any later version.
-
+   the Free Software Foundation, either version 3 of the License, or
+   (at your option) any later version.
+   
    This program is distributed in the hope that it will be useful,
    but WITHOUT ANY WARRANTY; without even the implied warranty of
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
    GNU General Public License for more details.
-
+   
    You should have received a copy of the GNU General Public License
-   along with this program; if not, write to the Free Software
-   Foundation, Inc., 51 Franklin Street, Fifth Floor,
-   Boston, MA 02110-1301, USA.  */
+   along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
 
 /* As a special exception, you may create a larger work that contains
    part or all of the Bison parser skeleton and distribute that work
    under terms of your choice, so long as that work isn't itself a
    parser generator using the skeleton or a modified version thereof
    as a parser skeleton.  Alternatively, if you modify or redistribute
    the parser skeleton itself, you may (at your option) remove this
    special exception, which will cause the skeleton and the resulting
    Bison output files to be licensed under the GNU General Public
    License without this special exception.
-
+   
    This special exception was added by the Free Software Foundation in
    version 2.2 of Bison.  */
 
+
 /* Tokens.  */
 #ifndef YYTOKENTYPE
 # define YYTOKENTYPE
    /* Put the tokens into the symbol table, so that GDB and other debuggers
       know about them.  */
    enum yytokentype {
      INVARIANT = 258,
      HIGH_PRECISION = 259,
@@ -75,170 +75,78 @@
      UNIFORM = 291,
      VARYING = 292,
      STRUCT = 293,
      VOID_TYPE = 294,
      WHILE = 295,
      SAMPLER2D = 296,
      SAMPLERCUBE = 297,
      SAMPLER_EXTERNAL_OES = 298,
-     IDENTIFIER = 299,
-     TYPE_NAME = 300,
-     FLOATCONSTANT = 301,
-     INTCONSTANT = 302,
-     BOOLCONSTANT = 303,
-     FIELD_SELECTION = 304,
-     LEFT_OP = 305,
-     RIGHT_OP = 306,
-     INC_OP = 307,
-     DEC_OP = 308,
-     LE_OP = 309,
-     GE_OP = 310,
-     EQ_OP = 311,
-     NE_OP = 312,
-     AND_OP = 313,
-     OR_OP = 314,
-     XOR_OP = 315,
-     MUL_ASSIGN = 316,
-     DIV_ASSIGN = 317,
-     ADD_ASSIGN = 318,
-     MOD_ASSIGN = 319,
-     LEFT_ASSIGN = 320,
-     RIGHT_ASSIGN = 321,
-     AND_ASSIGN = 322,
-     XOR_ASSIGN = 323,
-     OR_ASSIGN = 324,
-     SUB_ASSIGN = 325,
-     LEFT_PAREN = 326,
-     RIGHT_PAREN = 327,
-     LEFT_BRACKET = 328,
-     RIGHT_BRACKET = 329,
-     LEFT_BRACE = 330,
-     RIGHT_BRACE = 331,
-     DOT = 332,
-     COMMA = 333,
-     COLON = 334,
-     EQUAL = 335,
-     SEMICOLON = 336,
-     BANG = 337,
-     DASH = 338,
-     TILDE = 339,
-     PLUS = 340,
-     STAR = 341,
-     SLASH = 342,
-     PERCENT = 343,
-     LEFT_ANGLE = 344,
-     RIGHT_ANGLE = 345,
-     VERTICAL_BAR = 346,
-     CARET = 347,
-     AMPERSAND = 348,
-     QUESTION = 349
+     SAMPLER2DRECT = 299,
+     IDENTIFIER = 300,
+     TYPE_NAME = 301,
+     FLOATCONSTANT = 302,
+     INTCONSTANT = 303,
+     BOOLCONSTANT = 304,
+     FIELD_SELECTION = 305,
+     LEFT_OP = 306,
+     RIGHT_OP = 307,
+     INC_OP = 308,
+     DEC_OP = 309,
+     LE_OP = 310,
+     GE_OP = 311,
+     EQ_OP = 312,
+     NE_OP = 313,
+     AND_OP = 314,
+     OR_OP = 315,
+     XOR_OP = 316,
+     MUL_ASSIGN = 317,
+     DIV_ASSIGN = 318,
+     ADD_ASSIGN = 319,
+     MOD_ASSIGN = 320,
+     LEFT_ASSIGN = 321,
+     RIGHT_ASSIGN = 322,
+     AND_ASSIGN = 323,
+     XOR_ASSIGN = 324,
+     OR_ASSIGN = 325,
+     SUB_ASSIGN = 326,
+     LEFT_PAREN = 327,
+     RIGHT_PAREN = 328,
+     LEFT_BRACKET = 329,
+     RIGHT_BRACKET = 330,
+     LEFT_BRACE = 331,
+     RIGHT_BRACE = 332,
+     DOT = 333,
+     COMMA = 334,
+     COLON = 335,
+     EQUAL = 336,
+     SEMICOLON = 337,
+     BANG = 338,
+     DASH = 339,
+     TILDE = 340,
+     PLUS = 341,
+     STAR = 342,
+     SLASH = 343,
+     PERCENT = 344,
+     LEFT_ANGLE = 345,
+     RIGHT_ANGLE = 346,
+     VERTICAL_BAR = 347,
+     CARET = 348,
+     AMPERSAND = 349,
+     QUESTION = 350
    };
 #endif
-/* Tokens.  */
-#define INVARIANT 258
-#define HIGH_PRECISION 259
-#define MEDIUM_PRECISION 260
-#define LOW_PRECISION 261
-#define PRECISION 262
-#define ATTRIBUTE 263
-#define CONST_QUAL 264
-#define BOOL_TYPE 265
-#define FLOAT_TYPE 266
-#define INT_TYPE 267
-#define BREAK 268
-#define CONTINUE 269
-#define DO 270
-#define ELSE 271
-#define FOR 272
-#define IF 273
-#define DISCARD 274
-#define RETURN 275
-#define BVEC2 276
-#define BVEC3 277
-#define BVEC4 278
-#define IVEC2 279
-#define IVEC3 280
-#define IVEC4 281
-#define VEC2 282
-#define VEC3 283
-#define VEC4 284
-#define MATRIX2 285
-#define MATRIX3 286
-#define MATRIX4 287
-#define IN_QUAL 288
-#define OUT_QUAL 289
-#define INOUT_QUAL 290
-#define UNIFORM 291
-#define VARYING 292
-#define STRUCT 293
-#define VOID_TYPE 294
-#define WHILE 295
-#define SAMPLER2D 296
-#define SAMPLERCUBE 297
-#define SAMPLER_EXTERNAL_OES 298
-#define IDENTIFIER 299
-#define TYPE_NAME 300
-#define FLOATCONSTANT 301
-#define INTCONSTANT 302
-#define BOOLCONSTANT 303
-#define FIELD_SELECTION 304
-#define LEFT_OP 305
-#define RIGHT_OP 306
-#define INC_OP 307
-#define DEC_OP 308
-#define LE_OP 309
-#define GE_OP 310
-#define EQ_OP 311
-#define NE_OP 312
-#define AND_OP 313
-#define OR_OP 314
-#define XOR_OP 315
-#define MUL_ASSIGN 316
-#define DIV_ASSIGN 317
-#define ADD_ASSIGN 318
-#define MOD_ASSIGN 319
-#define LEFT_ASSIGN 320
-#define RIGHT_ASSIGN 321
-#define AND_ASSIGN 322
-#define XOR_ASSIGN 323
-#define OR_ASSIGN 324
-#define SUB_ASSIGN 325
-#define LEFT_PAREN 326
-#define RIGHT_PAREN 327
-#define LEFT_BRACKET 328
-#define RIGHT_BRACKET 329
-#define LEFT_BRACE 330
-#define RIGHT_BRACE 331
-#define DOT 332
-#define COMMA 333
-#define COLON 334
-#define EQUAL 335
-#define SEMICOLON 336
-#define BANG 337
-#define DASH 338
-#define TILDE 339
-#define PLUS 340
-#define STAR 341
-#define SLASH 342
-#define PERCENT 343
-#define LEFT_ANGLE 344
-#define RIGHT_ANGLE 345
-#define VERTICAL_BAR 346
-#define CARET 347
-#define AMPERSAND 348
-#define QUESTION 349
-
 
 
 
 #if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED
 typedef union YYSTYPE
+{
 
-{
+
     struct {
         TSourceLoc line;
         union {
             TString *string;
             float f;
             int i;
             bool b;
         };
@@ -258,19 +166,20 @@ typedef union YYSTYPE
             TPrecision precision;
             TQualifier qualifier;
             TFunction* function;
             TParameter param;
             TTypeLine typeLine;
             TTypeList* typeList;
         };
     } interm;
-}
-/* Line 1489 of yacc.c.  */
+
+
 
-	YYSTYPE;
+} YYSTYPE;
+# define YYSTYPE_IS_TRIVIAL 1
 # define yystype YYSTYPE /* obsolescent; will be withdrawn */
 # define YYSTYPE_IS_DECLARED 1
-# define YYSTYPE_IS_TRIVIAL 1
 #endif
 
 
 
+
--- a/gfx/angle/src/libEGL/Display.cpp
+++ b/gfx/angle/src/libEGL/Display.cpp
@@ -444,16 +444,17 @@ bool Display::createDevice()
     if (mD3d9Ex)
     {
         result = mDevice->QueryInterface(IID_IDirect3DDevice9Ex, (void**) &mDeviceEx);
         ASSERT(SUCCEEDED(result));
     }
 
     // Permanent non-default states
     mDevice->SetRenderState(D3DRS_POINTSPRITEENABLE, TRUE);
+    mDevice->SetRenderState(D3DRS_LASTPIXEL, FALSE);
 
     mSceneStarted = false;
 
     return true;
 }
 
 bool Display::resetDevice()
 {
--- a/gfx/angle/src/libGLESv2/Context.cpp
+++ b/gfx/angle/src/libGLESv2/Context.cpp
@@ -142,16 +142,17 @@ Context::Context(const egl::Config *conf
     bindReadFramebuffer(0);
     bindDrawFramebuffer(0);
     bindRenderbuffer(0);
 
     mState.currentProgram = 0;
 
     mState.packAlignment = 4;
     mState.unpackAlignment = 4;
+    mState.packReverseRowOrder = false;
 
     mVertexDataManager = NULL;
     mIndexDataManager = NULL;
     mBlit = NULL;
     mClosingIB = NULL;
 
     mInvalidEnum = false;
     mInvalidValue = false;
@@ -850,16 +851,26 @@ void Context::setUnpackAlignment(GLint a
     mState.unpackAlignment = alignment;
 }
 
 GLint Context::getUnpackAlignment() const
 {
     return mState.unpackAlignment;
 }
 
+void Context::setPackReverseRowOrder(bool reverseRowOrder)
+{
+    mState.packReverseRowOrder = reverseRowOrder;
+}
+
+bool Context::getPackReverseRowOrder() const
+{
+    return mState.packReverseRowOrder;
+}
+
 GLuint Context::createBuffer()
 {
     return mResourceManager->createBuffer();
 }
 
 GLuint Context::createProgram()
 {
     return mResourceManager->createProgram();
@@ -1268,16 +1279,17 @@ bool Context::getIntegerv(GLenum pname, 
       case GL_ARRAY_BUFFER_BINDING:             *params = mState.arrayBuffer.id();              break;
       case GL_ELEMENT_ARRAY_BUFFER_BINDING:     *params = mState.elementArrayBuffer.id();       break;
       //case GL_FRAMEBUFFER_BINDING:            // now equivalent to GL_DRAW_FRAMEBUFFER_BINDING_ANGLE
       case GL_DRAW_FRAMEBUFFER_BINDING_ANGLE:   *params = mState.drawFramebuffer;               break;
       case GL_READ_FRAMEBUFFER_BINDING_ANGLE:   *params = mState.readFramebuffer;               break;
       case GL_RENDERBUFFER_BINDING:             *params = mState.renderbuffer.id();             break;
       case GL_CURRENT_PROGRAM:                  *params = mState.currentProgram;                break;
       case GL_PACK_ALIGNMENT:                   *params = mState.packAlignment;                 break;
+      case GL_PACK_REVERSE_ROW_ORDER_ANGLE:     *params = mState.packReverseRowOrder;           break;
       case GL_UNPACK_ALIGNMENT:                 *params = mState.unpackAlignment;               break;
       case GL_GENERATE_MIPMAP_HINT:             *params = mState.generateMipmapHint;            break;
       case GL_FRAGMENT_SHADER_DERIVATIVE_HINT_OES: *params = mState.fragmentShaderDerivativeHint; break;
       case GL_ACTIVE_TEXTURE:                   *params = (mState.activeSampler + GL_TEXTURE0); break;
       case GL_STENCIL_FUNC:                     *params = mState.stencilFunc;                   break;
       case GL_STENCIL_REF:                      *params = mState.stencilRef;                    break;
       case GL_STENCIL_VALUE_MASK:               *params = mState.stencilMask;                   break;
       case GL_STENCIL_BACK_FUNC:                *params = mState.stencilBackFunc;               break;
@@ -1507,16 +1519,17 @@ bool Context::getQueryParameterInfo(GLen
       case GL_MAX_RENDERBUFFER_SIZE:
       case GL_NUM_SHADER_BINARY_FORMATS:
       case GL_NUM_COMPRESSED_TEXTURE_FORMATS:
       case GL_ARRAY_BUFFER_BINDING:
       case GL_FRAMEBUFFER_BINDING:
       case GL_RENDERBUFFER_BINDING:
       case GL_CURRENT_PROGRAM:
       case GL_PACK_ALIGNMENT:
+      case GL_PACK_REVERSE_ROW_ORDER_ANGLE:
       case GL_UNPACK_ALIGNMENT:
       case GL_GENERATE_MIPMAP_HINT:
       case GL_FRAGMENT_SHADER_DERIVATIVE_HINT_OES:
       case GL_RED_BITS:
       case GL_GREEN_BITS:
       case GL_BLUE_BITS:
       case GL_ALPHA_BITS:
       case GL_DEPTH_BITS:
@@ -2239,31 +2252,50 @@ void Context::readPixels(GLint x, GLint 
     if (!renderTarget)
     {
         return;   // Context must be lost, return silently
     }
 
     D3DSURFACE_DESC desc;
     renderTarget->GetDesc(&desc);
 
-    IDirect3DSurface9 *systemSurface;
-    HRESULT result = mDevice->CreateOffscreenPlainSurface(desc.Width, desc.Height, desc.Format, D3DPOOL_SYSTEMMEM, &systemSurface, NULL);
-
-    if (FAILED(result))
-    {
-        ASSERT(result == D3DERR_OUTOFVIDEOMEMORY || result == E_OUTOFMEMORY);
-        return error(GL_OUT_OF_MEMORY);
-    }
-
     if (desc.MultiSampleType != D3DMULTISAMPLE_NONE)
     {
         UNIMPLEMENTED();   // FIXME: Requires resolve using StretchRect into non-multisampled render target
         return error(GL_OUT_OF_MEMORY);
     }
 
+    HRESULT result;
+    IDirect3DSurface9 *systemSurface = NULL;
+    bool directToPixels = getPackReverseRowOrder() && getPackAlignment() <= 4 && mDisplay->isD3d9ExDevice() &&
+                          x == 0 && y == 0 && width == desc.Width && height == desc.Height &&
+                          desc.Format == D3DFMT_A8R8G8B8 && format == GL_BGRA_EXT && type == GL_UNSIGNED_BYTE;
+    if (directToPixels)
+    {
+        // Use the pixels ptr as a shared handle to write directly into client's memory
+        result = mDevice->CreateOffscreenPlainSurface(desc.Width, desc.Height, desc.Format,
+                                                      D3DPOOL_SYSTEMMEM, &systemSurface, &pixels);
+        if (FAILED(result))
+        {
+            // Try again without the shared handle
+            directToPixels = false;
+        }
+    }
+
+    if (!directToPixels)
+    {
+        result = mDevice->CreateOffscreenPlainSurface(desc.Width, desc.Height, desc.Format,
+                                                      D3DPOOL_SYSTEMMEM, &systemSurface, NULL);
+        if (FAILED(result))
+        {
+            ASSERT(result == D3DERR_OUTOFVIDEOMEMORY || result == E_OUTOFMEMORY);
+            return error(GL_OUT_OF_MEMORY);
+        }
+    }
+
     result = mDevice->GetRenderTargetData(renderTarget, systemSurface);
 
     if (FAILED(result))
     {
         systemSurface->Release();
 
         // It turns out that D3D will sometimes produce more error
         // codes than those documented.
@@ -2272,16 +2304,22 @@ void Context::readPixels(GLint x, GLint 
         else
         {
             UNREACHABLE();
             return;
         }
 
     }
 
+    if (directToPixels)
+    {
+        systemSurface->Release();
+        return;
+    }
+
     D3DLOCKED_RECT lock;
     RECT rect = transformPixelRect(x, y, width, height, desc.Height);
     rect.left = clamp(rect.left, 0L, static_cast<LONG>(desc.Width));
     rect.top = clamp(rect.top, 0L, static_cast<LONG>(desc.Height));
     rect.right = clamp(rect.right, 0L, static_cast<LONG>(desc.Width));
     rect.bottom = clamp(rect.bottom, 0L, static_cast<LONG>(desc.Height));
 
     result = systemSurface->LockRect(&lock, &rect, D3DLOCK_READONLY);
@@ -2289,20 +2327,31 @@ void Context::readPixels(GLint x, GLint 
     if (FAILED(result))
     {
         UNREACHABLE();
         systemSurface->Release();
 
         return;   // No sensible error to generate
     }
 
-    unsigned char *source = ((unsigned char*)lock.pBits) + lock.Pitch * (rect.bottom - rect.top - 1);
     unsigned char *dest = (unsigned char*)pixels;
     unsigned short *dest16 = (unsigned short*)pixels;
-    int inputPitch = -lock.Pitch;
+
+    unsigned char *source;
+    int inputPitch;
+    if (getPackReverseRowOrder())
+    {
+        source = (unsigned char*)lock.pBits;
+        inputPitch = lock.Pitch;
+    }
+    else
+    {
+        source = ((unsigned char*)lock.pBits) + lock.Pitch * (rect.bottom - rect.top - 1);
+        inputPitch = -lock.Pitch;
+    }
 
     for (int j = 0; j < rect.bottom - rect.top; j++)
     {
         if (desc.Format == D3DFMT_A8R8G8B8 &&
             format == GL_BGRA_EXT &&
             type == GL_UNSIGNED_BYTE)
         {
             // Fast path for EXT_read_format_bgra, given
@@ -2743,17 +2792,17 @@ void Context::drawArrays(GLenum mode, GL
     if (!cullSkipsDraw(mode))
     {
         mDisplay->startScene();
         
         mDevice->DrawPrimitive(primitiveType, 0, primitiveCount);
 
         if (mode == GL_LINE_LOOP)   // Draw the last segment separately
         {
-            drawClosingLine(first, first + count - 1);
+            drawClosingLine(0, count - 1, 0);
         }
     }
 }
 
 void Context::drawElements(GLenum mode, GLsizei count, GLenum type, const void *indices)
 {
     if (!mState.currentProgram)
     {
@@ -2808,17 +2857,17 @@ void Context::drawElements(GLenum mode, 
     if (!cullSkipsDraw(mode))
     {
         mDisplay->startScene();
 
         mDevice->DrawIndexedPrimitive(primitiveType, -(INT)indexInfo.minIndex, indexInfo.minIndex, vertexCount, indexInfo.startIndex, primitiveCount);
 
         if (mode == GL_LINE_LOOP)   // Draw the last segment separately
         {
-            drawClosingLine(count, type, indices);
+            drawClosingLine(count, type, indices, indexInfo.minIndex);
         }
     }
 }
 
 // Implements glFlush when block is false, glFinish when block is true
 void Context::sync(bool block)
 {
     IDirect3DQuery9 *eventQuery = NULL;
@@ -2860,17 +2909,17 @@ void Context::sync(bool block)
     eventQuery->Release();
 
     if (checkDeviceLost(result))
     {
         error(GL_OUT_OF_MEMORY);
     }
 }
 
-void Context::drawClosingLine(unsigned int first, unsigned int last)
+void Context::drawClosingLine(unsigned int first, unsigned int last, int minIndex)
 {
     IDirect3DIndexBuffer9 *indexBuffer = NULL;
     bool succeeded = false;
     UINT offset;
 
     if (supports32bitIndices())
     {
         const int spaceNeeded = 2 * sizeof(unsigned int);
@@ -2914,26 +2963,26 @@ void Context::drawClosingLine(unsigned i
         }
     }
     
     if (succeeded)
     {
         mDevice->SetIndices(mClosingIB->getBuffer());
         mAppliedIBSerial = mClosingIB->getSerial();
 
-        mDevice->DrawIndexedPrimitive(D3DPT_LINELIST, 0, 0, last, offset, 1);
+        mDevice->DrawIndexedPrimitive(D3DPT_LINELIST, -minIndex, minIndex, last, offset, 1);
     }
     else
     {
         ERR("Could not create an index buffer for closing a line loop.");
         error(GL_OUT_OF_MEMORY);
     }
 }
 
-void Context::drawClosingLine(GLsizei count, GLenum type, const void *indices)
+void Context::drawClosingLine(GLsizei count, GLenum type, const void *indices, int minIndex)
 {
     unsigned int first = 0;
     unsigned int last = 0;
 
     if (mState.elementArrayBuffer.get())
     {
         Buffer *indexBuffer = mState.elementArrayBuffer.get();
         intptr_t offset = reinterpret_cast<intptr_t>(indices);
@@ -2952,17 +3001,17 @@ void Context::drawClosingLine(GLsizei co
         break;
       case GL_UNSIGNED_INT:
         first = static_cast<const GLuint*>(indices)[0];
         last = static_cast<const GLuint*>(indices)[count - 1];
         break;
       default: UNREACHABLE();
     }
 
-    drawClosingLine(first, last);
+    drawClosingLine(first, last, minIndex);
 }
 
 void Context::recordInvalidEnum()
 {
     mInvalidEnum = true;
 }
 
 void Context::recordInvalidValue()
@@ -3443,16 +3492,18 @@ void Context::initExtensionString()
 
     // ANGLE-specific extensions
     mExtensionString += "GL_ANGLE_framebuffer_blit ";
     if (getMaxSupportedSamples() != 0)
     {
         mExtensionString += "GL_ANGLE_framebuffer_multisample ";
     }
 
+    mExtensionString += "GL_ANGLE_pack_reverse_row_order ";
+
     if (supportsDXT3Textures())
     {
         mExtensionString += "GL_ANGLE_texture_compression_dxt3 ";
     }
     if (supportsDXT5Textures())
     {
         mExtensionString += "GL_ANGLE_texture_compression_dxt5 ";
     }
--- a/gfx/angle/src/libGLESv2/Context.h
+++ b/gfx/angle/src/libGLESv2/Context.h
@@ -214,16 +214,17 @@ struct State
     BindingPointer<Renderbuffer> renderbuffer;
     GLuint currentProgram;
 
     VertexAttribute vertexAttribute[MAX_VERTEX_ATTRIBS];
     BindingPointer<Texture> samplerTexture[TEXTURE_TYPE_COUNT][MAX_COMBINED_TEXTURE_IMAGE_UNITS_VTF];
 
     GLint unpackAlignment;
     GLint packAlignment;
+    bool packReverseRowOrder;
 };
 
 // Helper class to construct and cache vertex declarations
 class VertexDeclarationCache
 {
   public:
     VertexDeclarationCache();
     ~VertexDeclarationCache();
@@ -355,16 +356,19 @@ class Context
     const VertexAttributeArray &getVertexAttributes();
 
     void setUnpackAlignment(GLint alignment);
     GLint getUnpackAlignment() const;
 
     void setPackAlignment(GLint alignment);
     GLint getPackAlignment() const;
 
+    void setPackReverseRowOrder(bool reverseRowOrder);
+    bool getPackReverseRowOrder() const;
+
     // These create  and destroy methods are merely pass-throughs to 
     // ResourceManager, which owns these object types
     GLuint createBuffer();
     GLuint createShader(GLenum type);
     GLuint createProgram();
     GLuint createTexture();
     GLuint createRenderbuffer();
 
@@ -422,18 +426,18 @@ class Context
 
     void readPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLsizei *bufSize, void* pixels);
     void clear(GLbitfield mask);
     void drawArrays(GLenum mode, GLint first, GLsizei count);
     void drawElements(GLenum mode, GLsizei count, GLenum type, const void *indices);
     void sync(bool block);   // flush/finish
 
 	// Draw the last segment of a line loop
-    void drawClosingLine(unsigned int first, unsigned int last);
-    void drawClosingLine(GLsizei count, GLenum type, const void *indices);
+    void drawClosingLine(unsigned int first, unsigned int last, int minIndex);
+    void drawClosingLine(GLsizei count, GLenum type, const void *indices, int minIndex);
 
     void recordInvalidEnum();
     void recordInvalidValue();
     void recordInvalidOperation();
     void recordOutOfMemory();
     void recordInvalidFramebufferOperation();
 
     GLenum getError();
--- a/gfx/angle/src/libGLESv2/Renderbuffer.cpp
+++ b/gfx/angle/src/libGLESv2/Renderbuffer.cpp
@@ -67,22 +67,22 @@ IDirect3DSurface9 *RenderbufferTexture::
 
 IDirect3DSurface9 *RenderbufferTexture::getDepthStencil()
 {
     return NULL;
 }
 
 GLsizei RenderbufferTexture::getWidth() const
 {
-    return mTexture->getWidth();
+    return mTexture->getWidth(0);
 }
  
 GLsizei RenderbufferTexture::getHeight() const
 {
-    return mTexture->getHeight();
+    return mTexture->getHeight(0);
 }
  
 GLenum RenderbufferTexture::getInternalFormat() const
 {
     return mTexture->getInternalFormat();
 }
 
 D3DFORMAT RenderbufferTexture::getD3DFormat() const
--- a/gfx/angle/src/libGLESv2/Texture.cpp
+++ b/gfx/angle/src/libGLESv2/Texture.cpp
@@ -1708,24 +1708,30 @@ Texture2D::~Texture2D()
     }
 }
 
 GLenum Texture2D::getTarget() const
 {
     return GL_TEXTURE_2D;
 }
 
-GLsizei Texture2D::getWidth() const
+GLsizei Texture2D::getWidth(GLint level) const
 {
-    return mImageArray[0].getWidth();
+    if (level < IMPLEMENTATION_MAX_TEXTURE_LEVELS)
+        return mImageArray[level].getWidth();
+    else
+        return 0;
 }
 
-GLsizei Texture2D::getHeight() const
+GLsizei Texture2D::getHeight(GLint level) const
 {
-    return mImageArray[0].getHeight();
+    if (level < IMPLEMENTATION_MAX_TEXTURE_LEVELS)
+        return mImageArray[level].getHeight();
+    else
+        return 0;
 }
 
 GLenum Texture2D::getInternalFormat() const
 {
     return mImageArray[0].getFormat();
 }
 
 GLenum Texture2D::getType() const
@@ -2336,24 +2342,30 @@ TextureCubeMap::~TextureCubeMap()
     mTexture = NULL;
 }
 
 GLenum TextureCubeMap::getTarget() const
 {
     return GL_TEXTURE_CUBE_MAP;
 }
 
-GLsizei TextureCubeMap::getWidth() const
+GLsizei TextureCubeMap::getWidth(GLint level) const
 {
-    return mImageArray[0][0].getWidth();
+    if (level < IMPLEMENTATION_MAX_TEXTURE_LEVELS)
+        return mImageArray[0][level].getWidth();
+    else
+        return 0;
 }
 
-GLsizei TextureCubeMap::getHeight() const
+GLsizei TextureCubeMap::getHeight(GLint level) const
 {
-    return mImageArray[0][0].getHeight();
+    if (level < IMPLEMENTATION_MAX_TEXTURE_LEVELS)
+        return mImageArray[0][level].getHeight();
+    else
+        return 0;
 }
 
 GLenum TextureCubeMap::getInternalFormat() const
 {
     return mImageArray[0][0].getFormat();
 }
 
 GLenum TextureCubeMap::getType() const
--- a/gfx/angle/src/libGLESv2/Texture.h
+++ b/gfx/angle/src/libGLESv2/Texture.h
@@ -179,18 +179,18 @@ class Texture : public RefCountObject
     bool setUsage(GLenum usage);
 
     GLenum getMinFilter() const;
     GLenum getMagFilter() const;
     GLenum getWrapS() const;
     GLenum getWrapT() const;
     GLenum getUsage() const;
 
-    virtual GLsizei getWidth() const = 0;
-    virtual GLsizei getHeight() const = 0;
+    virtual GLsizei getWidth(GLint level) const = 0;
+    virtual GLsizei getHeight(GLint level) const = 0;
     virtual GLenum getInternalFormat() const = 0;
     virtual GLenum getType() const = 0;
     virtual D3DFORMAT getD3DFormat() const = 0;
 
     virtual bool isSamplerComplete() const = 0;
     virtual bool isCompressed() const = 0;
 
     IDirect3DBaseTexture9 *getTexture();
@@ -272,18 +272,18 @@ class Texture2D : public Texture
 {
   public:
     explicit Texture2D(GLuint id);
 
     ~Texture2D();
 
     virtual GLenum getTarget() const;
 
-    virtual GLsizei getWidth() const;
-    virtual GLsizei getHeight() const;
+    virtual GLsizei getWidth(GLint level) const;
+    virtual GLsizei getHeight(GLint level) const;
     virtual GLenum getInternalFormat() const;
     virtual GLenum getType() const;
     virtual D3DFORMAT getD3DFormat() const;
 
     void setImage(GLint level, GLsizei width, GLsizei height, GLenum format, GLenum type, GLint unpackAlignment, const void *pixels);
     void setCompressedImage(GLint level, GLenum format, GLsizei width, GLsizei height, GLsizei imageSize, const void *pixels);
     void subImage(GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, GLint unpackAlignment, const void *pixels);
     void subImageCompressed(GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const void *pixels);
@@ -346,18 +346,18 @@ class TextureCubeMap : public Texture
 {
   public:
     explicit TextureCubeMap(GLuint id);
 
     ~TextureCubeMap();
 
     virtual GLenum getTarget() const;
     
-    virtual GLsizei getWidth() const;
-    virtual GLsizei getHeight() const;
+    virtual GLsizei getWidth(GLint level) const;
+    virtual GLsizei getHeight(GLint level) const;
     virtual GLenum getInternalFormat() const;
     virtual GLenum getType() const;
     virtual D3DFORMAT getD3DFormat() const;
 
     void setImagePosX(GLint level, GLsizei width, GLsizei height, GLenum format, GLenum type, GLint unpackAlignment, const void *pixels);
     void setImageNegX(GLint level, GLsizei width, GLsizei height, GLenum format, GLenum type, GLint unpackAlignment, const void *pixels);
     void setImagePosY(GLint level, GLsizei width, GLsizei height, GLenum format, GLenum type, GLint unpackAlignment, const void *pixels);
     void setImageNegY(GLint level, GLsizei width, GLsizei height, GLenum format, GLenum type, GLint unpackAlignment, const void *pixels);
--- a/gfx/angle/src/libGLESv2/libGLESv2.cpp
+++ b/gfx/angle/src/libGLESv2/libGLESv2.cpp
@@ -48,16 +48,51 @@ bool validImageSize(GLint level, GLsizei
     if (gl::isPow2(width) && gl::isPow2(height))
     {
         return true;
     }
 
     return false;
 }
 
+bool validateSubImageParams(bool compressed, GLsizei width, GLsizei height, GLint xoffset, GLint yoffset, GLint level, GLenum format, gl::Texture *texture)
+{
+    if (!texture)
+    {
+        return error(GL_INVALID_OPERATION, false);
+    }
+
+    if (compressed != texture->isCompressed())
+    {
+        return error(GL_INVALID_OPERATION, false);
+    }
+
+    if (format != GL_NONE && format != texture->getInternalFormat())
+    {
+        return error(GL_INVALID_OPERATION, false);
+    }
+
+    if (compressed)
+    {
+        if ((width % 4 != 0 && width != texture->getWidth(0)) || 
+            (height % 4 != 0 && height != texture->getHeight(0)))
+        {
+            return error(GL_INVALID_OPERATION, false);
+        }
+    }
+
+    if (xoffset + width > texture->getWidth(level) ||
+        yoffset + height > texture->getHeight(level))
+    {
+        return error(GL_INVALID_VALUE, false);
+    }
+
+    return true;
+}
+
 // check for combinations of format and type that are valid for ReadPixels
 bool validReadFormatType(GLenum format, GLenum type)
 {
     switch (format)
     {
       case GL_RGBA:
         switch (type)
         {
@@ -1020,56 +1055,28 @@ void __stdcall glCompressedTexSubImage2D
             {
                 return error(GL_INVALID_OPERATION); // we wait to check the offsets until this point, because the multiple-of-four restriction
                                                     // does not exist unless DXT textures are supported.
             }
 
             if (target == GL_TEXTURE_2D)
             {
                 gl::Texture2D *texture = context->getTexture2D();
-
-                if (!texture)
-                {
-                    return error(GL_INVALID_OPERATION);
-                }
-
-                if (!texture->isCompressed())
+                if (validateSubImageParams(true, width, height, xoffset, yoffset, level, GL_NONE, texture))
                 {
-                    return error(GL_INVALID_OPERATION);
+                    texture->subImageCompressed(level, xoffset, yoffset, width, height, format, imageSize, data);
                 }
-
-                if ((width % 4 != 0 && width != texture->getWidth()) || 
-                    (height % 4 != 0 && height != texture->getHeight()))
-                {
-                    return error(GL_INVALID_OPERATION);
-                }
-
-                texture->subImageCompressed(level, xoffset, yoffset, width, height, format, imageSize, data);
             }
             else if (gl::IsCubemapTextureTarget(target))
             {
                 gl::TextureCubeMap *texture = context->getTextureCubeMap();
-
-                if (!texture)
-                {
-                    return error(GL_INVALID_OPERATION);
-                }
-
-                if (!texture->isCompressed())
+                if (validateSubImageParams(true, width, height, xoffset, yoffset, level, GL_NONE, texture))
                 {
-                    return error(GL_INVALID_OPERATION);
+                    texture->subImageCompressed(target, level, xoffset, yoffset, width, height, format, imageSize, data);
                 }
-
-                if ((width % 4 != 0 && width != texture->getWidth()) || 
-                    (height % 4 != 0 && height != texture->getHeight()))
-                {
-                    return error(GL_INVALID_OPERATION);
-                }
-
-                texture->subImageCompressed(target, level, xoffset, yoffset, width, height, format, imageSize, data);
             }
             else
             {
                 UNREACHABLE();
             }
         }
     }
     catch(std::bad_alloc&)
@@ -1320,19 +1327,19 @@ void __stdcall glCopyTexSubImage2D(GLenu
                 texture = context->getTexture2D();
             }
             else if (gl::IsCubemapTextureTarget(target))
             {
                 texture = context->getTextureCubeMap();
             }
             else UNREACHABLE();
 
-            if (!texture)
-            {
-                return error(GL_INVALID_OPERATION);
+            if (!validateSubImageParams(false, width, height, xoffset, yoffset, level, GL_NONE, texture))
+            {
+                return; // error already registered by validateSubImageParams
             }
 
             GLenum textureFormat = texture->getInternalFormat();
 
             // [OpenGL ES 2.0.24] table 3.9
             switch (textureFormat)
             {
               case GL_ALPHA:
@@ -4149,16 +4156,20 @@ void __stdcall glPixelStorei(GLenum pnam
                 if (param != 1 && param != 2 && param != 4 && param != 8)
                 {
                     return error(GL_INVALID_VALUE);
                 }
 
                 context->setPackAlignment(param);
                 break;
 
+              case GL_PACK_REVERSE_ROW_ORDER_ANGLE:
+                context->setPackReverseRowOrder(param != 0);
+                break;
+
               default:
                 return error(GL_INVALID_ENUM);
             }
         }
     }
     catch(std::bad_alloc&)
     {
         return error(GL_OUT_OF_MEMORY);
@@ -5033,16 +5044,36 @@ void __stdcall glTexStorage2DEXT(GLenum 
         {
             return error(GL_INVALID_ENUM);
         }
 
         gl::Context *context = gl::getNonLostContext();
 
         if (context)
         {
+            switch (target)
+            {
+              case GL_TEXTURE_2D:
+                if (width > context->getMaximumTextureDimension() ||
+                    height > context->getMaximumTextureDimension())
+                {
+                    return error(GL_INVALID_VALUE);
+                }
+                break;
+              case GL_TEXTURE_CUBE_MAP:
+                if (width > context->getMaximumCubeTextureDimension() ||
+                    height > context->getMaximumCubeTextureDimension())
+                {
+                    return error(GL_INVALID_VALUE);
+                }
+                break;
+              default:
+                return error(GL_INVALID_ENUM);
+            }
+
             if (levels != 1 && !context->supportsNonPower2Texture())
             {
                 if (!gl::isPow2(width) || !gl::isPow2(height))
                 {
                     return error(GL_INVALID_OPERATION);
                 }
             }
 
@@ -5187,44 +5218,28 @@ void __stdcall glTexSubImage2D(GLenum ta
                 {
                     return error(GL_INVALID_ENUM);
                 }
             }
 
             if (target == GL_TEXTURE_2D)
             {
                 gl::Texture2D *texture = context->getTexture2D();
-
-                if (!texture)
-                {
-                    return error(GL_INVALID_OPERATION);
-                }
-
-                if (texture->isCompressed())
+                if (validateSubImageParams(false, width, height, xoffset, yoffset, level, format, texture))
                 {
-                    return error(GL_INVALID_OPERATION);
+                    texture->subImage(level, xoffset, yoffset, width, height, format, type, context->getUnpackAlignment(), pixels);
                 }
-
-                if (format != texture->getInternalFormat())
-                {
-                    return error(GL_INVALID_OPERATION);
-                }
-
-                texture->subImage(level, xoffset, yoffset, width, height, format, type, context->getUnpackAlignment(), pixels);
             }
             else if (gl::IsCubemapTextureTarget(target))
             {
                 gl::TextureCubeMap *texture = context->getTextureCubeMap();
-
-                if (!texture)
+                if (validateSubImageParams(false, width, height, xoffset, yoffset, level, format, texture))
                 {
-                    return error(GL_INVALID_OPERATION);
+                    texture->subImage(target, level, xoffset, yoffset, width, height, format, type, context->getUnpackAlignment(), pixels);
                 }
-
-                texture->subImage(target, level, xoffset, yoffset, width, height, format, type, context->getUnpackAlignment(), pixels);
             }
             else
             {
                 UNREACHABLE();
             }
         }
     }
     catch(std::bad_alloc&)