skeletons: style/comment changes

* data/c++.m4, data/c.m4, data/glr.c: Here.
This commit is contained in:
Akim Demaille
2018-09-09 13:46:42 +02:00
parent d6fb1813ee
commit 79331541ae
3 changed files with 17 additions and 12 deletions

View File

@@ -24,12 +24,21 @@ b4_percent_define_ifdef([[api.value.union.name]],
m4_include(b4_pkgdatadir/[c.m4])
b4_percent_define_check_kind([api.namespace], [code], [deprecated])
b4_percent_define_check_kind([parser_class_name], [code], [deprecated])
## ----- ##
## C++. ##
## ----- ##
# b4_comment(TEXT, [PREFIX])
# --------------------------
# Put TEXT in comment. Prefix all the output lines with PREFIX.
m4_define([b4_comment],
[b4_comment_([$1], [$2// ], [$2// ])])
# b4_inline(hh|cc)
# ----------------
# Expand to `inline\n ` if $1 is hh.
@@ -40,12 +49,7 @@ m4_define([b4_inline],
]],
[m4_fatal([$0: invalid argument: $1])])])
## -------- ##
## Checks. ##
## -------- ##
b4_percent_define_check_kind([api.namespace], [code], [deprecated])
b4_percent_define_check_kind([parser_class_name], [code], [deprecated])
## ---------------- ##
## Default values. ##

View File

@@ -263,11 +263,6 @@ m4_define([b4_attribute_define],
])
## ---------##
## Values. ##
## ---------##
# b4_null_define
# --------------
# Portability issues: define a YY_NULLPTR appropriate for the current
@@ -288,6 +283,12 @@ m4_define([b4_null_define],
# Return a null pointer constant.
m4_define([b4_null], [YY_NULLPTR])
## ---------##
## Values. ##
## ---------##
# b4_integral_parser_table_define(TABLE-NAME, CONTENT, COMMENT)
# -------------------------------------------------------------
# Define "yy<TABLE-NAME>" whose contents is CONTENT.

View File

@@ -217,9 +217,9 @@ b4_copyright([Skeleton implementation for Bison GLR parsers in C],
/* C GLR parser skeleton written by Paul Hilfinger. */
]b4_identification
]b4_identification[
b4_percent_code_get([[top]])[
]b4_percent_code_get([[top]])[
]m4_if(b4_api_prefix, [yy], [],
[[/* Substitute the type names. */
#define YYSTYPE ]b4_api_PREFIX[STYPE]b4_locations_if([[