Remove comment support from the main lexer.
authorKenneth Graunke <kenneth@whitecape.org>
Mon, 21 Jun 2010 22:12:34 +0000 (15:12 -0700)
committerIan Romanick <ian.d.romanick@intel.com>
Wed, 23 Jun 2010 21:14:57 +0000 (14:14 -0700)
Now handled by the preprocessor.

glsl_lexer.lpp

index 9a3037a..c15c99c 100644 (file)
@@ -41,9 +41,8 @@
 %option never-interactive
 %option prefix="_mesa_glsl_"
 %option extra-type="struct _mesa_glsl_parse_state *"
-%option stack
 
-%x PP COMMENT
+%x PP
 
 DEC_INT                [1-9][0-9]*
 HEX_INT                0[xX][0-9a-fA-F]+
@@ -54,14 +53,6 @@ SPCP         [ \t]+
 HASH           ^{SPC}#{SPC}
 %%
 
-"/*"                   { yy_push_state(COMMENT, yyscanner); }
-<COMMENT>[^*\n]*
-<COMMENT>[^*\n]*\n     { yylineno++; yycolumn = 0; }
-<COMMENT>"*"+[^*/\n]*
-<COMMENT>"*"+[^*/\n]*\n { yylineno++; yycolumn = 0; }
-<COMMENT>"*"+"/"        { yy_pop_state(yyscanner); }
-
-\/\/.*\n               { yylineno++; yycolumn = 0; }
 [ \r\t]+               ;
 
     /* Preprocessor tokens. */