]> granicus.if.org Git - flex/commitdiff
scanner: Avoid creating unused label
authorChristos Zoulas <christos@zoulas.com>
Sun, 22 Jan 2017 17:28:08 +0000 (18:28 +0100)
committerWill Estes <westes575@gmail.com>
Mon, 23 Jan 2017 17:06:53 +0000 (12:06 -0500)
src/gen.c

index e0dc776f533e0a76151a6b72f26ceebc48102ce2..590e5d8d1cc787fd61c69d5ba22e9fea02bc507a 100644 (file)
--- a/src/gen.c
+++ b/src/gen.c
@@ -509,8 +509,12 @@ void gen_find_action (void)
                indent_puts ("yy_current_state = *--YY_G(yy_state_ptr);");
                indent_puts ("YY_G(yy_lp) = yy_accept[yy_current_state];");
 
+               if (!variable_trailing_context_rules)
+                       outn ("m4_ifdef( [[M4_YY_USES_REJECT]],\n[[");
                if(reject_really_used)
                        outn ("find_rule: /* we branch to this label when backing up */");
+               if (!variable_trailing_context_rules)
+                       outn ("]])\n");
 
                indent_puts
                        ("for ( ; ; ) /* until we find what rule we matched */");