Commit 7eeb9b66 by Jamie Madill Committed by Shannon Woods

Delete dead-code for handling comments and invalid octal integers. These are

already handled by the preprocessor. TRAC #23158 Signed-off-by: Nicolas Capens Merged-by: Jamie Madill Authored-by: alokp@chromium.org git-svn-url: https://code.google.com/p/angleproject/source/detail?r=2189 Review URL: https://codereview.appspot.com/8632053
parent fe345bfd
......@@ -65,7 +65,7 @@ static int floatsuffix_check(TParseContext* context);
%option yylineno reentrant bison-bridge
%option stack
%option extra-type="TParseContext*"
%x COMMENT FIELDS
%x FIELDS
D [0-9]
L [a-zA-Z_]
......@@ -79,15 +79,6 @@ O [0-7]
TParseContext* context = yyextra;
%}
/* Single-line comments */
"//"[^\n]* ;
/* Multi-line comments */
"/*" { yy_push_state(COMMENT, yyscanner); }
<COMMENT>. |
<COMMENT>\n ;
<COMMENT>"*/" { yy_pop_state(yyscanner); }
"invariant" { return INVARIANT; }
"highp" { return HIGH_PRECISION; }
"mediump" { return MEDIUM_PRECISION; }
......@@ -306,7 +297,6 @@ O [0-7]
0[xX]{H}+ { yylval->lex.i = static_cast<int>(strtol(yytext, 0, 0)); return INTCONSTANT; }
0{O}+ { yylval->lex.i = static_cast<int>(strtol(yytext, 0, 0)); return INTCONSTANT; }
0{D}+ { context->error(yylineno, "Invalid Octal number.", yytext); context->recover(); return 0;}
{D}+ { yylval->lex.i = static_cast<int>(strtol(yytext, 0, 0)); return INTCONSTANT; }
0[xX]{H}+[uU] { return uint_constant(context); }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment