Matteo Bruni : d3dcompiler: Don' t take the sign as part of the numeric token.

Alexandre Julliard julliard at winehq.org
Fri Nov 9 11:03:23 CST 2012


Module: wine
Branch: master
Commit: a5203e1a79d49cb363cbe90bf33a3f274e96443a
URL:    http://source.winehq.org/git/wine.git/?a=commit;h=a5203e1a79d49cb363cbe90bf33a3f274e96443a

Author: Matteo Bruni <mbruni at codeweavers.com>
Date:   Fri Nov  9 15:20:36 2012 +0100

d3dcompiler: Don't take the sign as part of the numeric token.

---

 dlls/d3dcompiler_43/hlsl.l |    8 ++++----
 1 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/dlls/d3dcompiler_43/hlsl.l b/dlls/d3dcompiler_43/hlsl.l
index 49fb042..f40e3c9 100644
--- a/dlls/d3dcompiler_43/hlsl.l
+++ b/dlls/d3dcompiler_43/hlsl.l
@@ -184,15 +184,15 @@ row_major               {return KW_ROW_MAJOR;           }
                                 return NEW_IDENTIFIER;
                         }
 
-[+-]?[0-9]*\.[0-9]+([eE][+-]?[0-9]+)?[h|H|f|F]? {
+[0-9]*\.[0-9]+([eE][+-]?[0-9]+)?[h|H|f|F]? {
                             hlsl_lval.floatval = atof(yytext);
                             return C_FLOAT;
                         }
-[+-]?[0-9]+\.([eE][+-]?[0-9]+)?[h|H|f|F]? {
+[0-9]+\.([eE][+-]?[0-9]+)?[h|H|f|F]? {
                             hlsl_lval.floatval = atof(yytext);
                             return C_FLOAT;
                         }
-[+-]?[0-9]+([eE][+-]?[0-9]+)?[h|H|f|F] {
+[0-9]+([eE][+-]?[0-9]+)?[h|H|f|F] {
                             hlsl_lval.floatval = atof(yytext);
                             return C_FLOAT;
                         }
@@ -204,7 +204,7 @@ row_major               {return KW_ROW_MAJOR;           }
                             sscanf(yytext, "0%o", &hlsl_lval.intval);
                             return C_INTEGER;
                         }
-\-?[0-9]+               {
+[0-9]+                  {
                             hlsl_lval.intval = (atoi(yytext));
                             return C_INTEGER;
                         }




More information about the wine-cvs mailing list