summaryrefslogtreecommitdiff
path: root/flex.skl
diff options
context:
space:
mode:
authorJohn Millaway <john43@users.sourceforge.net>2002-11-29 03:34:05 +0000
committerJohn Millaway <john43@users.sourceforge.net>2002-11-29 03:34:05 +0000
commitd4368099baad9cbfcc5a8ce2e7a7ed6fff181f5a (patch)
treeb422595459d6aefc29a78e23518551aeb3220b63 /flex.skl
parent1c18c5a7a8fc70f1bb12119997641208caecaed8 (diff)
Fixed bug in SECOND yyless definition where argument was not enclosed in parentheses.
Diffstat (limited to 'flex.skl')
-rw-r--r--flex.skl7
1 files changed, 4 insertions, 3 deletions
diff --git a/flex.skl b/flex.skl
index 874f635..cbbbca8 100644
--- a/flex.skl
+++ b/flex.skl
@@ -1864,12 +1864,13 @@ void yyFlexLexer::LexerError( yyconst char msg[] )
do \
{ \
/* Undo effects of setting up yytext. */ \
- YY_LESS_LINENO(n);\
+ int yyless_macro_arg = (n); \
+ YY_LESS_LINENO(yyless_macro_arg);\
yytext[yyleng] = YY_G(yy_hold_char); \
- YY_G(yy_c_buf_p) = yytext + n; \
+ YY_G(yy_c_buf_p) = yytext + yyless_macro_arg; \
YY_G(yy_hold_char) = *YY_G(yy_c_buf_p); \
*YY_G(yy_c_buf_p) = '\0'; \
- yyleng = n; \
+ yyleng = yyless_macro_arg; \
} \
while ( 0 )