]> granicus.if.org Git - flex/commitdiff
Added some comments.
authorJohn Millaway <john43@users.sourceforge.net>
Sun, 28 Jul 2002 20:02:20 +0000 (20:02 +0000)
committerJohn Millaway <john43@users.sourceforge.net>
Sun, 28 Jul 2002 20:02:20 +0000 (20:02 +0000)
flex.skl

index df44804bd8fa44fb8e8a43bdfc16fab5b04b20f2..85824d79a65b10069f98b7aab6ede61d1a1611c7 100644 (file)
--- a/flex.skl
+++ b/flex.skl
@@ -239,6 +239,13 @@ extern FILE *yyin, *yyout;
 #define EOB_ACT_LAST_MATCH 2
 
 #ifdef YY_USE_LINENO
+/* Note: We specifically omit the test for yy_rule_can_match_eol because it requires
+ *       access to the local variable yy_act. Since yyless() is a macro, it would break
+ *       existing scanners that call yyless() from OUTSIDE yylex. 
+ *       One obvious solution it to make yy_act a global. I tried that, and saw
+ *       a 5% performance hit in a non-yylineno scanner, because yy_act is
+ *       normally declared as a register variable-- so it's not worth it.
+ */
 #define  YY_LESS_LINENO(n) \
         do { \
                        int yyl;\