m4_changecom()
m4_divert(0)dnl
b4_defines_if(
-[@output @output_header_name@
+[@output b4_spec_defines_file
b4_copyright([Skeleton interface for Bison LALR(1) parsers in C++],
[2002, 2003, 2004, 2005, 2006])
dnl FIXME: This is wrong, we want computed header guards.
#ifndef PARSER_HEADER_H
# define PARSER_HEADER_H
-]m4_ifdef([b4_start_header],
-[[/* Copy the %start-header blocks. */
-]b4_user_start_header])[
+]m4_ifdef([b4_requires],
+[[/* Copy the %requires blocks. */
+]b4_user_requires])[
#include <string>
#include <iostream>
# define YYSTYPE b4_namespace::b4_parser_class_name::semantic_type
#endif
])
-m4_ifdef([b4_end_header],
-[[/* Copy the %end-header blocks. */
-]b4_end_header])[]dnl
+m4_ifdef([b4_provides],
+[[/* Copy the %provides blocks. */
+]b4_user_provides])[]dnl
[#endif /* ! defined PARSER_HEADER_H */]
])dnl
-@output @output_parser_name@
+@output b4_parser_file_name
b4_copyright([Skeleton implementation for Bison LALR(1) parsers in C++],
[2002, 2003, 2004, 2005, 2006])
m4_if(b4_prefix, [yy], [],
#define yylex b4_prefix[]lex])[
/* First part of user declarations. */
-]b4_pre_prologue
+]b4_user_pre_prologue
-b4_defines_if([
-#include @output_header_name@])[
+b4_defines_if([[
+#include "@basename(]b4_spec_defines_file[@)"]])[
/* User implementation prologue. */
]b4_user_post_prologue[
#else /* !YYDEBUG */
+# define YYCDEBUG if (false) std::cerr
# define YY_SYMBOL_PRINT(Title, Type, Value, Location)
# define YY_REDUCE_PRINT(Rule)
# define YY_STACK_PRINT()
#endif /* !YYDEBUG */
-#define YYCDEBUG if (false) std::cerr
#define YYACCEPT goto yyacceptlab
#define YYABORT goto yyabortlab
#define YYERROR goto yyerrorlab