diff options
author | Matt Turner <[email protected]> | 2012-11-20 17:23:42 -0800 |
---|---|---|
committer | Matt Turner <[email protected]> | 2012-11-28 10:26:53 -0800 |
commit | aed466192a78ff2bb3db877a9599424de708cf90 (patch) | |
tree | 33e7e1f4700aff357776d57e703ec9fc5cf5815b /src/glsl/glcpp/glcpp-lex.l | |
parent | 91ca053714957aca5205122e8478002c62cc4344 (diff) |
glcpp: Reject #version and #line not followed by whitespace
Fixes part of es3conform's preprocess16_frag test.
Reviewed-by: Carl Worth <[email protected]>
Diffstat (limited to 'src/glsl/glcpp/glcpp-lex.l')
-rw-r--r-- | src/glsl/glcpp/glcpp-lex.l | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/glsl/glcpp/glcpp-lex.l b/src/glsl/glcpp/glcpp-lex.l index 783c545495e..4f0dd34d30d 100644 --- a/src/glsl/glcpp/glcpp-lex.l +++ b/src/glsl/glcpp/glcpp-lex.l @@ -120,7 +120,7 @@ HEXADECIMAL_INTEGER 0[xX][0-9a-fA-F]+[uU]? return SPACE; } -{HASH}version { +{HASH}version{HSPACE}+ { yylval->str = ralloc_strdup (yyextra, yytext); yyextra->space_tokens = 0; return HASH_VERSION; @@ -135,7 +135,7 @@ HEXADECIMAL_INTEGER 0[xX][0-9a-fA-F]+[uU]? return OTHER; } -{HASH}line { +{HASH}line{HSPACE}+ { return HASH_LINE; } |