zenilib  0.5.3.0
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
ExpressionParser.cpp File Reference
#include "ExpressionParser.h"
#include <cassert>
#include <sstream>
#include "DiagnosticsBase.h"
#include "Lexer.h"
#include "Token.h"
#include <stdint.h>

Go to the source code of this file.

Namespaces

 pp
 

Macros

#define YY_(Msgid)   Msgid
 
#define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN
 
#define YY_IGNORE_MAYBE_UNINITIALIZED_END
 
#define YY_INITIAL_VALUE(Value)   = Value
 
#define YY_LOCATION_PRINT(File, Loc)   ((void) 0)
 
#define YY_NULL   0
 
#define YY_REDUCE_PRINT(Rule)
 
#define YY_STACK_PRINT(Bottom, Top)
 
#define YY_SYMBOL_PRINT(Title, Type, Value, Location)
 
#define YYABORT   goto yyabortlab
 
#define YYACCEPT   goto yyacceptlab
 
#define YYBACKUP(Token, Value)
 
#define YYBISON   1
 
#define YYBISON_VERSION   "2.7"
 
#define yychar   ppchar
 
#define yyclearin   (yychar = YYEMPTY)
 
#define YYCOPY(Dst, Src, Count)
 
#define YYCOPY_NEEDED   1
 
#define yydebug   ppdebug
 
#define YYDEBUG   0
 
#define YYDPRINTF(Args)
 
#define YYEMPTY   (-2)
 
#define YYENABLE_NLS   0
 
#define YYEOF   0
 
#define YYERRCODE   256
 
#define yyerrok   (yyerrstatus = 0)
 
#define yyerror   pperror
 
#define YYERROR   goto yyerrorlab
 
#define YYERROR_VERBOSE   0
 
#define YYFAIL   goto yyerrlab
 
#define YYFINAL   14
 
#define YYFREE   free
 
#define YYID(N)   (N)
 
#define YYINITDEPTH   200
 
#define YYLAST   175
 
#define yylex   pplex
 
#define YYLEX   yylex (&yylval, context)
 
#define YYLTYPE_IS_TRIVIAL   1
 
#define yylval   pplval
 
#define YYMALLOC   malloc
 
#define YYMAXDEPTH   10000
 
#define YYMAXUTOK   267
 
#define yynerrs   ppnerrs
 
#define YYNNTS   3
 
#define YYNRULES   26
 
#define YYNSTATES   52
 
#define YYNTOKENS   27
 
#define YYPACT_NINF   -11
 
#define yypact_value_is_default(Yystate)   (!!((Yystate) == (-11)))
 
#define yyparse   ppparse
 
#define YYPOPSTACK(N)   (yyvsp -= (N), yyssp -= (N))
 
#define YYPULL   1
 
#define YYPURE   1
 
#define YYPUSH   0
 
#define YYRECOVERING()   (!!yyerrstatus)
 
#define YYSIZE_MAXIMUM   ((YYSIZE_T) -1)
 
#define YYSIZE_T   unsigned int
 
#define YYSKELETON_NAME   "yacc.c"
 
#define YYSTACK_ALLOC   YYMALLOC
 
#define YYSTACK_ALLOC_MAXIMUM   YYSIZE_MAXIMUM
 
#define YYSTACK_BYTES(N)
 
#define YYSTACK_FREE   YYFREE
 
#define YYSTACK_GAP_MAXIMUM   (sizeof (union yyalloc) - 1)
 
#define YYSTACK_RELOCATE(Stack_alloc, Stack)
 
#define YYSTYPE_IS_DECLARED   1
 
#define YYSTYPE_IS_TRIVIAL   1
 
#define YYTABLE_NINF   -1
 
#define yytable_value_is_error(Yytable_value)   YYID (0)
 
#define YYTERROR   1
 
#define YYTOKENTYPE
 
#define YYTRANSLATE(YYX)   ((unsigned int) (YYX) <= YYMAXUTOK ? yytranslate[YYX] : YYUNDEFTOK)
 
#define YYUNDEFTOK   2
 
#define YYUSE(E)   ((void) (E))
 

Typedefs

typedef intmax_t YYSTYPE
 
typedef short int yytype_int16
 
typedef short int yytype_int8
 
typedef unsigned short int yytype_uint16
 
typedef unsigned char yytype_uint8
 

Enumerations

enum  yytokentype {
  INVARIANT = 258, HIGH_PRECISION = 259, MEDIUM_PRECISION = 260, LOW_PRECISION = 261,
  PRECISION = 262, ATTRIBUTE = 263, CONST_QUAL = 264, BOOL_TYPE = 265,
  FLOAT_TYPE = 266, INT_TYPE = 267, BREAK = 268, CONTINUE = 269,
  DO = 270, ELSE = 271, FOR = 272, IF = 273,
  DISCARD = 274, RETURN = 275, BVEC2 = 276, BVEC3 = 277,
  BVEC4 = 278, IVEC2 = 279, IVEC3 = 280, IVEC4 = 281,
  VEC2 = 282, VEC3 = 283, VEC4 = 284, MATRIX2 = 285,
  MATRIX3 = 286, MATRIX4 = 287, IN_QUAL = 288, OUT_QUAL = 289,
  INOUT_QUAL = 290, UNIFORM = 291, VARYING = 292, STRUCT = 293,
  VOID_TYPE = 294, WHILE = 295, SAMPLER2D = 296, SAMPLERCUBE = 297,
  SAMPLER_EXTERNAL_OES = 298, SAMPLER2DRECT = 299, IDENTIFIER = 300, TYPE_NAME = 301,
  FLOATCONSTANT = 302, INTCONSTANT = 303, BOOLCONSTANT = 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,
  INVARIANT = 258, HIGH_PRECISION = 259, MEDIUM_PRECISION = 260, LOW_PRECISION = 261,
  PRECISION = 262, ATTRIBUTE = 263, CONST_QUAL = 264, BOOL_TYPE = 265,
  FLOAT_TYPE = 266, INT_TYPE = 267, BREAK = 268, CONTINUE = 269,
  DO = 270, ELSE = 271, FOR = 272, IF = 273,
  DISCARD = 274, RETURN = 275, BVEC2 = 276, BVEC3 = 277,
  BVEC4 = 278, IVEC2 = 279, IVEC3 = 280, IVEC4 = 281,
  VEC2 = 282, VEC3 = 283, VEC4 = 284, MATRIX2 = 285,
  MATRIX3 = 286, MATRIX4 = 287, IN_QUAL = 288, OUT_QUAL = 289,
  INOUT_QUAL = 290, UNIFORM = 291, VARYING = 292, STRUCT = 293,
  VOID_TYPE = 294, WHILE = 295, SAMPLER2D = 296, SAMPLERCUBE = 297,
  SAMPLER_EXTERNAL_OES = 298, SAMPLER2DRECT = 299, IDENTIFIER = 300, TYPE_NAME = 301,
  FLOATCONSTANT = 302, INTCONSTANT = 303, BOOLCONSTANT = 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,
  TOK_CONST_INT = 258, TOK_OP_OR = 259, TOK_OP_AND = 260, TOK_OP_NE = 261,
  TOK_OP_EQ = 262, TOK_OP_GE = 263, TOK_OP_LE = 264, TOK_OP_RIGHT = 265,
  TOK_OP_LEFT = 266, TOK_UNARY = 267
}
 

Functions

 for (;;)
 
 if (yyss+yystacksize-1<=yyssp)
 
 if (yychar==YYEMPTY)
 
 if (yychar<=YYEOF)
 
 if (yyn<=0)
 
 if (!yyerrstatus)
 
 if (yyerrstatus==3)
 
int ppparse ()
 
 switch (yytype)
 
 switch (yyn)
 
 while (yyssp!=yyss)
 
yyexhaustedlab YY_ ("memory exhausted"))
 
YYSTYPE yylval YY_INITIAL_VALUE (yyval_default)
 
 YY_REDUCE_PRINT (yyn)
 
 YY_STACK_PRINT (yyss, yyssp)
 
 YY_SYMBOL_PRINT (yymsg, yytype, yyvaluep, yylocationp)
 
 YY_SYMBOL_PRINT ("Next token is", yytoken,&yylval,&yylloc)
 
 YY_SYMBOL_PRINT ("Shifting", yytoken,&yylval,&yylloc)
 
 YY_SYMBOL_PRINT ("-> $$ =", yyr1[yyn],&yyval,&yyloc)
 
YY_IGNORE_MAYBE_UNINITIALIZED_END YY_SYMBOL_PRINT ("Shifting", yystos[yyn], yyvsp, yylsp)
 
 yydestruct ("Cleanup: discarding lookahead", yytoken,&yylval, context)
 
 YYDPRINTF ((stderr,"Starting parse\n"))
 
 YYDPRINTF ((stderr,"Entering state %d\n", yystate))
 
static void yyerror (Context *context, const char *reason)
 
return YYID (yyresult)
 
static int yylex (YYSTYPE *lvalp, Context *context)
 
 YYPOPSTACK (yylen)
 
 YYSTACK_FREE (yyss)
 
 YYUSE (context)
 

Variables

yynewstate __pad0__
 
yyexhaustedlab __pad10__
 
yyreturn __pad11__
 
yysetstate __pad1__
 
yybackup __pad2__
 
yydefault __pad3__
 
yyreduce __pad4__
 
yyerrlab __pad5__
 
yyerrorlab __pad6__
 
yyerrlab1 __pad7__
 
yyacceptlab __pad8__
 
yyabortlab __pad9__
 
Context * context
 
 else
 
 YYACCEPT
 
goto yybackup
 
 yychar = YYEMPTY
 
static const yytype_int8 yycheck []
 
static const yytype_uint8 yydefact []
 
goto yydefault
 
static const yytype_int8 yydefgoto []
 
goto yyerrlab
 
goto yyerrlab1
 
int yyerrstatus = 0
 
int yylen = 0
 
static void const char * yymsg = "Deleting"
 
int yyn = yytoken
 
int yynerrs = 0
 
YY_IGNORE_MAYBE_UNINITIALIZED_END
goto 
yynewstate
 
static const yytype_int16 yypact []
 
static const yytype_int8 yypgoto []
 
static const yytype_uint8 yyr1 []
 
static const yytype_uint8 yyr2 []
 
goto yyreduce
 
int yyresult = 2
 
goto yyreturn
 
goto yysetstate
 
yytype_int16yyss
 
yytype_int16 yyssa [YYINITDEPTH]
 
yytype_int16yyssp = yyss = yyssa
 
YYSIZE_T yystacksize = YYINITDEPTH
 
int yystate = 0
 
static const yytype_uint8 yystos []
 
static const yytype_uint8 yytable []
 
int yytoken = 0
 
static const yytype_uint8 yytranslate []
 
int yytype
 
YYSTYPE yyval = yyvsp[1-yylen]
 
static YYSTYPE yyval_default
 
YYSTYPEyyvaluep
 
YYSTYPEyyvs
 
YYSTYPE yyvsa [YYINITDEPTH]
 
YYSTYPEyyvsp = yyvs = yyvsa
 

Macro Definition Documentation

#define YY_ (   Msgid)    Msgid

Definition at line 257 of file ExpressionParser.cpp.

#define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN

Definition at line 1219 of file ExpressionParser.cpp.

#define YY_IGNORE_MAYBE_UNINITIALIZED_END

Definition at line 1220 of file ExpressionParser.cpp.

#define YY_INITIAL_VALUE (   Value)    = Value

Definition at line 1216 of file ExpressionParser.cpp.

#define YY_LOCATION_PRINT (   File,
  Loc 
)    ((void) 0)

Definition at line 699 of file ExpressionParser.cpp.

#define YY_NULL   0

Definition at line 133 of file ExpressionParser.cpp.

#define YY_REDUCE_PRINT (   Rule)

Definition at line 876 of file ExpressionParser.cpp.

#define YY_STACK_PRINT (   Bottom,
  Top 
)

Definition at line 875 of file ExpressionParser.cpp.

#define YY_SYMBOL_PRINT (   Title,
  Type,
  Value,
  Location 
)

Definition at line 874 of file ExpressionParser.cpp.

#define YYABORT   goto yyabortlab

Definition at line 654 of file ExpressionParser.cpp.

Referenced by for(), if(), and switch().

#define YYACCEPT   goto yyacceptlab

Definition at line 653 of file ExpressionParser.cpp.

#define YYBACKUP (   Token,
  Value 
)
Value:
{ \
yychar = (Token); \
yylval = (Value); \
goto yybackup; \
} \
{ \
yyerror (context, YY_("syntax error: cannot back up")); \
} \
while (YYID (0))
#define YYPOPSTACK(N)
#define YYID(N)
else
int yystate
if(!yyg->yy_init)
int yylen
yytype_int16 * yyssp
goto yybackup
#define yylval
#define YYEMPTY
#define YY_(Msgid)
#define YYERROR
#define yyerror
TParseContext * context
#define yychar
while(1)

Definition at line 675 of file ExpressionParser.cpp.

#define YYBISON   1

Definition at line 44 of file ExpressionParser.cpp.

#define YYBISON_VERSION   "2.7"

Definition at line 47 of file ExpressionParser.cpp.

#define yychar   ppchar

Definition at line 67 of file ExpressionParser.cpp.

#define yyclearin   (yychar = YYEMPTY)

Definition at line 649 of file ExpressionParser.cpp.

#define YYCOPY (   Dst,
  Src,
  Count 
)
Value:
do \
{ \
for (yyi = 0; yyi < (Count); yyi++) \
(Dst)[yyi] = (Src)[yyi]; \
} \
while (YYID (0))
#define YYID(N)
for(;;)
while(1)
#define YYSIZE_T

Definition at line 405 of file ExpressionParser.cpp.

#define YYCOPY_NEEDED   1

Definition at line 377 of file ExpressionParser.cpp.

#define yydebug   ppdebug

Definition at line 68 of file ExpressionParser.cpp.

#define YYDEBUG   0

Definition at line 148 of file ExpressionParser.cpp.

#define YYDPRINTF (   Args)

Definition at line 873 of file ExpressionParser.cpp.

#define YYEMPTY   (-2)

Definition at line 650 of file ExpressionParser.cpp.

Referenced by if().

#define YYENABLE_NLS   0

Definition at line 108 of file ExpressionParser.cpp.

#define YYEOF   0

Definition at line 651 of file ExpressionParser.cpp.

Referenced by if().

#define YYERRCODE   256

Definition at line 694 of file ExpressionParser.cpp.

#define yyerrok   (yyerrstatus = 0)

Definition at line 648 of file ExpressionParser.cpp.

#define yyerror   pperror

Definition at line 65 of file ExpressionParser.cpp.

Referenced by if().

#define YYERROR   goto yyerrorlab

Definition at line 655 of file ExpressionParser.cpp.

#define YYERROR_VERBOSE   0

Definition at line 142 of file ExpressionParser.cpp.

#define YYFAIL   goto yyerrlab

Definition at line 665 of file ExpressionParser.cpp.

#define YYFINAL   14

Definition at line 418 of file ExpressionParser.cpp.

#define YYFREE   free

Definition at line 347 of file ExpressionParser.cpp.

#define YYID (   N)    (N)

Definition at line 270 of file ExpressionParser.cpp.

#define YYINITDEPTH   200

Definition at line 882 of file ExpressionParser.cpp.

#define YYLAST   175

Definition at line 420 of file ExpressionParser.cpp.

Referenced by for().

#define yylex   pplex

Definition at line 64 of file ExpressionParser.cpp.

#define YYLEX   yylex (&yylval, context)

Definition at line 707 of file ExpressionParser.cpp.

Referenced by if().

#define YYLTYPE_IS_TRIVIAL   1

Definition at line 109 of file ExpressionParser.cpp.

#define yylval   pplval

Definition at line 66 of file ExpressionParser.cpp.

#define YYMALLOC   malloc

Definition at line 340 of file ExpressionParser.cpp.

#define YYMAXDEPTH   10000

Definition at line 893 of file ExpressionParser.cpp.

Referenced by if().

#define YYMAXUTOK   267

Definition at line 433 of file ExpressionParser.cpp.

#define yynerrs   ppnerrs

Definition at line 69 of file ExpressionParser.cpp.

Referenced by if().

#define YYNNTS   3

Definition at line 425 of file ExpressionParser.cpp.

#define YYNRULES   26

Definition at line 427 of file ExpressionParser.cpp.

#define YYNSTATES   52

Definition at line 429 of file ExpressionParser.cpp.

#define YYNTOKENS   27

Definition at line 423 of file ExpressionParser.cpp.

#define YYPACT_NINF   -11

Definition at line 565 of file ExpressionParser.cpp.

#define yypact_value_is_default (   Yystate)    (!!((Yystate) == (-11)))

Definition at line 608 of file ExpressionParser.cpp.

Referenced by for().

#define yyparse   ppparse

Definition at line 63 of file ExpressionParser.cpp.

Referenced by glslang_parse(), and pp::ExpressionParser::parse().

#define YYPOPSTACK (   N)    (yyvsp -= (N), yyssp -= (N))

Definition at line 1270 of file ExpressionParser.cpp.

#define YYPULL   1

Definition at line 59 of file ExpressionParser.cpp.

#define YYPURE   1

Definition at line 53 of file ExpressionParser.cpp.

#define YYPUSH   0

Definition at line 56 of file ExpressionParser.cpp.

#define YYRECOVERING ( )    (!!yyerrstatus)

Definition at line 673 of file ExpressionParser.cpp.

#define YYSIZE_MAXIMUM   ((YYSIZE_T) -1)

Definition at line 247 of file ExpressionParser.cpp.

#define YYSIZE_T   unsigned int

Definition at line 243 of file ExpressionParser.cpp.

Referenced by if().

#define YYSKELETON_NAME   "yacc.c"

Definition at line 50 of file ExpressionParser.cpp.

#define YYSTACK_ALLOC   YYMALLOC

Definition at line 326 of file ExpressionParser.cpp.

Referenced by if().

#define YYSTACK_ALLOC_MAXIMUM   YYSIZE_MAXIMUM

Definition at line 329 of file ExpressionParser.cpp.

#define YYSTACK_BYTES (   N)
Value:
((N) * (sizeof (yytype_int16) + sizeof (YYSTYPE)) \
short int yytype_int16
union YYSTYPE YYSTYPE
#define YYSTACK_GAP_MAXIMUM

Definition at line 373 of file ExpressionParser.cpp.

Referenced by if().

#define YYSTACK_FREE   YYFREE

Definition at line 327 of file ExpressionParser.cpp.

#define YYSTACK_GAP_MAXIMUM   (sizeof (union yyalloc) - 1)

Definition at line 369 of file ExpressionParser.cpp.

#define YYSTACK_RELOCATE (   Stack_alloc,
  Stack 
)
Value:
do \
{ \
YYSIZE_T yynewbytes; \
YYCOPY (&yyptr->Stack_alloc, Stack, yysize); \
Stack = &yyptr->Stack_alloc; \
yynewbytes = yystacksize * sizeof (*Stack) + YYSTACK_GAP_MAXIMUM; \
yyptr += yynewbytes / sizeof (*yyptr); \
} \
while (YYID (0))
#define YYID(N)
#define YYCOPY(Dst, Src, Count)
#define YYSTACK_GAP_MAXIMUM
while(1)
#define YYSIZE_T
YYSIZE_T yystacksize

Definition at line 384 of file ExpressionParser.cpp.

Referenced by if().

#define YYSTYPE_IS_DECLARED   1

Definition at line 111 of file ExpressionParser.cpp.

#define YYSTYPE_IS_TRIVIAL   1

Definition at line 110 of file ExpressionParser.cpp.

#define YYTABLE_NINF   -1

Definition at line 585 of file ExpressionParser.cpp.

#define yytable_value_is_error (   Yytable_value)    YYID (0)

Definition at line 611 of file ExpressionParser.cpp.

Referenced by if().

#define YYTERROR   1

Definition at line 693 of file ExpressionParser.cpp.

Referenced by for().

#define YYTOKENTYPE

Definition at line 156 of file ExpressionParser.cpp.

#define YYTRANSLATE (   YYX)    ((unsigned int) (YYX) <= YYMAXUTOK ? yytranslate[YYX] : YYUNDEFTOK)

Definition at line 435 of file ExpressionParser.cpp.

#define YYUNDEFTOK   2

Definition at line 432 of file ExpressionParser.cpp.

#define YYUSE (   E)    ((void) (E))

Definition at line 263 of file ExpressionParser.cpp.

Typedef Documentation

typedef intmax_t YYSTYPE

Definition at line 106 of file ExpressionParser.cpp.

typedef short int yytype_int16

Definition at line 230 of file ExpressionParser.cpp.

typedef short int yytype_int8

Definition at line 218 of file ExpressionParser.cpp.

typedef unsigned short int yytype_uint16

Definition at line 224 of file ExpressionParser.cpp.

typedef unsigned char yytype_uint8

Definition at line 209 of file ExpressionParser.cpp.

Enumeration Type Documentation

Enumerator
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 
SAMPLER2DRECT 
IDENTIFIER 
TYPE_NAME 
FLOATCONSTANT 
INTCONSTANT 
BOOLCONSTANT 
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 
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 
SAMPLER2DRECT 
IDENTIFIER 
TYPE_NAME 
FLOATCONSTANT 
INTCONSTANT 
BOOLCONSTANT 
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 
TOK_CONST_INT 
TOK_OP_OR 
TOK_OP_AND 
TOK_OP_NE 
TOK_OP_EQ 
TOK_OP_GE 
TOK_OP_LE 
TOK_OP_RIGHT 
TOK_OP_LEFT 
TOK_UNARY 

Definition at line 159 of file ExpressionParser.cpp.

Function Documentation

if ( yychar  = YYEMPTY)

Definition at line 1383 of file ExpressionParser.cpp.

References YYDPRINTF, and YYLEX.

if ( yychar<=  YYEOF)

Definition at line 1389 of file ExpressionParser.cpp.

References YYDPRINTF, and YYEOF.

if ( yyn<=  0)

Definition at line 1406 of file ExpressionParser.cpp.

References yyerrlab, yyn, yyreduce, and yytable_value_is_error.

if ( yyerrstatus)

Definition at line 1700 of file ExpressionParser.cpp.

References YY_, yyerror, yymsg, yynerrs, YYSTACK_ALLOC, and YYSTACK_FREE.

if ( yyerrstatus  = = 3)

Definition at line 1741 of file ExpressionParser.cpp.

References YYABORT, yydestruct(), YYEMPTY, YYEOF, and yylval.

int ppparse ( )
switch ( yytype  )

Definition at line 1163 of file ExpressionParser.cpp.

switch ( yyn  )

Definition at line 1462 of file ExpressionParser.cpp.

References pp::Diagnostics::DIVISION_BY_ZERO, YYABORT, YYACCEPT, and yyval.

while ( yyssp!  = yyss)

Definition at line 1866 of file ExpressionParser.cpp.

References yydestruct(), and YYPOPSTACK.

yyexhaustedlab YY_ ( "memory exhausted"  )
YYSTYPE yylval YY_INITIAL_VALUE ( yyval_default  )
YY_REDUCE_PRINT ( yyn  )
YY_STACK_PRINT ( yyss  ,
yyssp   
)
YY_SYMBOL_PRINT ( yymsg  ,
yytype  ,
yyvaluep  ,
yylocationp   
)
YY_SYMBOL_PRINT ( "Next token is"  ,
yytoken  ,
yylval,
yylloc 
)
YY_SYMBOL_PRINT ( "Shifting"  ,
yytoken  ,
yylval,
yylloc 
)
YY_SYMBOL_PRINT ( )
YY_IGNORE_MAYBE_UNINITIALIZED_END YY_SYMBOL_PRINT ( "Shifting"  ,
yystos  [yyn],
yyvsp  ,
yylsp   
)
yydestruct ( "Cleanup: discarding lookahead"  ,
yytoken  ,
yylval,
context   
)
YYDPRINTF ( (stderr,"Starting parse\n")  )
YYDPRINTF ( (stderr,"Entering state %d\n", yystate)  )
void yyerror ( Context *  context,
const char *  reason 
)
static

Definition at line 1939 of file ExpressionParser.cpp.

References pp::Diagnostics::INVALID_EXPRESSION.

return YYID ( yyresult  )
YYPOPSTACK ( yylen  )
YYSTACK_FREE ( yyss  )
YYUSE ( context  )

Variable Documentation

yynewstate __pad0__

Definition at line 1294 of file ExpressionParser.cpp.

yyexhaustedlab __pad10__

Definition at line 1848 of file ExpressionParser.cpp.

yyreturn __pad11__

Definition at line 1858 of file ExpressionParser.cpp.

yysetstate __pad1__

Definition at line 1297 of file ExpressionParser.cpp.

yybackup __pad2__

Definition at line 1376 of file ExpressionParser.cpp.

yydefault __pad3__

Definition at line 1437 of file ExpressionParser.cpp.

yyreduce __pad4__

Definition at line 1448 of file ExpressionParser.cpp.

yyerrlab __pad5__

Definition at line 1697 of file ExpressionParser.cpp.

yyerrorlab __pad6__

Definition at line 1774 of file ExpressionParser.cpp.

yyerrlab1 __pad7__

Definition at line 1789 of file ExpressionParser.cpp.

yyacceptlab __pad8__

Definition at line 1833 of file ExpressionParser.cpp.

yyabortlab __pad9__

Definition at line 1840 of file ExpressionParser.cpp.

int Context* context

Definition at line 1153 of file ExpressionParser.cpp.

else
Initial value:
{
#define YYTRANSLATE(YYX)
int yytoken
#define yychar

Definition at line 1395 of file ExpressionParser.cpp.

YYACCEPT

Definition at line 1363 of file ExpressionParser.cpp.

goto yybackup

Definition at line 1365 of file ExpressionParser.cpp.

yychar = YYEMPTY

Definition at line 1285 of file ExpressionParser.cpp.

const yytype_int8 yycheck[]
static
Initial value:
=
{
2, 3, 4, 5, 6, 15, 16, 17, 18, 19,
20, 21, 0, 15, 16, 17, 18, 19, 20, 21,
22, 23, 24, 25, 26, 27, 28, 29, 30, 31,
32, 4, 5, 6, 7, 8, 9, 10, 11, 12,
13, 14, 15, 16, 17, 18, 19, 20, 21, 3,
19, 20, 21, 26, 17, 18, 19, 20, 21, -1,
-1, -1, -1, 17, 18, -1, -1, -1, -1, 23,
24, 25, 4, 5, 6, 7, 8, 9, 10, 11,
12, 13, 14, 15, 16, 17, 18, 19, 20, 21,
5, 6, 7, 8, 9, 10, 11, 12, 13, 14,
15, 16, 17, 18, 19, 20, 21, 6, 7, 8,
9, 10, 11, 12, 13, 14, 15, 16, 17, 18,
19, 20, 21, 7, 8, 9, 10, 11, 12, 13,
14, 15, 16, 17, 18, 19, 20, 21, 8, 9,
10, 11, 12, 13, 14, 15, 16, 17, 18, 19,
20, 21, 9, 10, 11, 12, 13, 14, 15, 16,
17, 18, 19, 20, 21, 11, 12, 13, 14, 15,
16, 17, 18, 19, 20, 21
}

Definition at line 614 of file ExpressionParser.cpp.

const yytype_uint8 yydefact[]
static
Initial value:
=
{
0, 3, 0, 0, 0, 0, 0, 0, 2, 25,
24, 22, 23, 0, 1, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 26, 4, 5, 6, 7, 8, 9,
10, 14, 13, 11, 12, 15, 16, 18, 17, 21,
20, 19
}

Definition at line 547 of file ExpressionParser.cpp.

goto yydefault

Definition at line 1378 of file ExpressionParser.cpp.

const yytype_int8 yydefgoto[]
static
Initial value:
=
{
-1, 7, 8
}

Definition at line 558 of file ExpressionParser.cpp.

goto yyerrlab

Definition at line 1439 of file ExpressionParser.cpp.

goto yyerrlab1

Definition at line 1762 of file ExpressionParser.cpp.

yyerrstatus = 0

Definition at line 1234 of file ExpressionParser.cpp.

yylen = 0

Definition at line 1274 of file ExpressionParser.cpp.

yymsg = "Deleting"
static

Definition at line 1150 of file ExpressionParser.cpp.

Referenced by if().

yyn = yytoken

Definition at line 1255 of file ExpressionParser.cpp.

yynerrs = 0

Definition at line 1230 of file ExpressionParser.cpp.

goto yynewstate

Definition at line 1430 of file ExpressionParser.cpp.

const yytype_int16 yypact[]
static
Initial value:
=
{
46, -11, 46, 46, 46, 46, 46, 12, 68, -11,
-11, -11, -11, 27, -11, 46, 46, 46, 46, 46,
46, 46, 46, 46, 46, 46, 46, 46, 46, 46,
46, 46, 46, -11, 85, 101, 116, 130, 143, 154,
154, -10, -10, -10, -10, 37, 37, 31, 31, -11,
-11, -11
}

Definition at line 566 of file ExpressionParser.cpp.

const yytype_int8 yypgoto[]
static
Initial value:
=
{
-11, -11, -2
}

Definition at line 577 of file ExpressionParser.cpp.

const yytype_uint8 yyr1[]
static
Initial value:
=
{
0, 27, 28, 29, 29, 29, 29, 29, 29, 29,
29, 29, 29, 29, 29, 29, 29, 29, 29, 29,
29, 29, 29, 29, 29, 29, 29
}

Definition at line 529 of file ExpressionParser.cpp.

const yytype_uint8 yyr2[]
static
Initial value:
=
{
0, 2, 1, 1, 3, 3, 3, 3, 3, 3,
3, 3, 3, 3, 3, 3, 3, 3, 3, 3,
3, 3, 2, 2, 2, 2, 3
}

Definition at line 537 of file ExpressionParser.cpp.

goto yyreduce

Definition at line 1440 of file ExpressionParser.cpp.

yyresult = 2

Definition at line 1256 of file ExpressionParser.cpp.

goto yyreturn

Definition at line 1834 of file ExpressionParser.cpp.

goto yysetstate

Definition at line 1286 of file ExpressionParser.cpp.

yytype_int16* yyss

Definition at line 1245 of file ExpressionParser.cpp.

Definition at line 1244 of file ExpressionParser.cpp.

yyssp = yyss = yyssa

Definition at line 1246 of file ExpressionParser.cpp.

yystacksize = YYINITDEPTH

Definition at line 1253 of file ExpressionParser.cpp.

yystate = 0

Definition at line 1232 of file ExpressionParser.cpp.

const yytype_uint8 yystos[]
static
Initial value:
=
{
0, 3, 17, 18, 23, 24, 25, 28, 29, 29,
29, 29, 29, 29, 0, 4, 5, 6, 7, 8,
9, 10, 11, 12, 13, 14, 15, 16, 17, 18,
19, 20, 21, 26, 29, 29, 29, 29, 29, 29,
29, 29, 29, 29, 29, 29, 29, 29, 29, 29,
29, 29
}

Definition at line 638 of file ExpressionParser.cpp.

const yytype_uint8 yytable[]
static
Initial value:
=
{
9, 10, 11, 12, 13, 26, 27, 28, 29, 30,
31, 32, 14, 34, 35, 36, 37, 38, 39, 40,
41, 42, 43, 44, 45, 46, 47, 48, 49, 50,
51, 15, 16, 17, 18, 19, 20, 21, 22, 23,
24, 25, 26, 27, 28, 29, 30, 31, 32, 1,
30, 31, 32, 33, 28, 29, 30, 31, 32, 0,
0, 0, 0, 2, 3, 0, 0, 0, 0, 4,
5, 6, 15, 16, 17, 18, 19, 20, 21, 22,
23, 24, 25, 26, 27, 28, 29, 30, 31, 32,
16, 17, 18, 19, 20, 21, 22, 23, 24, 25,
26, 27, 28, 29, 30, 31, 32, 17, 18, 19,
20, 21, 22, 23, 24, 25, 26, 27, 28, 29,
30, 31, 32, 18, 19, 20, 21, 22, 23, 24,
25, 26, 27, 28, 29, 30, 31, 32, 19, 20,
21, 22, 23, 24, 25, 26, 27, 28, 29, 30,
31, 32, 20, 21, 22, 23, 24, 25, 26, 27,
28, 29, 30, 31, 32, 22, 23, 24, 25, 26,
27, 28, 29, 30, 31, 32
}

Definition at line 586 of file ExpressionParser.cpp.

int yytoken = 0

Definition at line 1258 of file ExpressionParser.cpp.

const yytype_uint8 yytranslate[]
static
Initial value:
=
{
0, 2, 2, 2, 2, 2, 2, 2, 2, 2,
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
2, 2, 2, 23, 2, 2, 2, 21, 8, 2,
25, 26, 19, 17, 2, 18, 2, 20, 2, 2,
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
11, 2, 12, 2, 2, 2, 2, 2, 2, 2,
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
2, 2, 2, 2, 7, 2, 2, 2, 2, 2,
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
2, 2, 2, 2, 6, 2, 24, 2, 2, 2,
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
2, 2, 2, 2, 2, 2, 1, 2, 3, 4,
5, 9, 10, 13, 14, 15, 16, 22
}

Definition at line 439 of file ExpressionParser.cpp.

int yytype

Definition at line 1151 of file ExpressionParser.cpp.

yyval = yyvsp[1-yylen]

Definition at line 1261 of file ExpressionParser.cpp.

YYSTYPE yyval_default
static
Initial value:
{
int yychar
#define yychar

Definition at line 1199 of file ExpressionParser.cpp.

YYSTYPE* yyvaluep

Definition at line 1152 of file ExpressionParser.cpp.

YYSTYPE* yyvs

Definition at line 1250 of file ExpressionParser.cpp.

Definition at line 1249 of file ExpressionParser.cpp.