mirror of
https://git.savannah.gnu.org/git/bison.git
synced 2026-03-13 22:33:03 +00:00
yacc: fix handling of CPP guards when no header is generated
When no header was to be generated, Bison would issue:
/* In a future release of Bison, this section will be replaced
by #include "". */
#ifndef YY_
# define YY_
It now properly generates nothing.
* data/c.m4 (b4_cpp_guard_open, b4_cpp_guard_close): Issue nothing when
the file name is empty.
* data/yacc.c: Do not generate the above comment when there is no header
to generate.
* NEWS: Update.
This commit is contained in:
@@ -345,9 +345,11 @@ m4_if(b4_api_prefix, [yy], [],
|
||||
# define YYERROR_VERBOSE ]b4_error_verbose_flag[
|
||||
#endif
|
||||
|
||||
/* In a future release of Bison, this section will be replaced
|
||||
]m4_ifval(m4_quote(b4_spec_defines_file),
|
||||
[[/* In a future release of Bison, this section will be replaced
|
||||
by #include "@basename(]b4_spec_defines_file[@)". */
|
||||
]b4_shared_declarations[
|
||||
]])dnl
|
||||
b4_shared_declarations[
|
||||
|
||||
/* Copy the second part of user declarations. */
|
||||
]b4_user_post_prologue
|
||||
|
||||
Reference in New Issue
Block a user