mirror of
https://git.savannah.gnu.org/git/bison.git
synced 2026-03-19 17:23:02 +00:00
tests: disable GCC7 warnings for some tests
With GCC7 we have warnings (false positive):
x8.c: In function 'x8_parse':
x8.c:1233:16: error: 'yylval' may be used uninitialized in this function [-Werror=maybe-uninitialized]
yylval = *yypushed_val;
~~~~~~~^~~~~~~~~~~~~~~
x8.c: In function 'x8_pull_parse':
x8.c:1233:16: error: 'yylval' may be used uninitialized in this function [-Werror=maybe-uninitialized]
yylval = *yypushed_val;
~~~~~~~^~~~~~~~~~~~~~~
See also 9645a2b20e.
* tests/local.at (AT_PUSH_IF): New.
(AT_BISON_OPTION_POPDEFS): Pop it, and pop AT_PURE_IF.
* tests/headers.at (Several parsers, Several parsers): Disable these
warnings when in push parser.
This commit is contained in:
@@ -180,6 +180,8 @@ m4_pushdef([AT_PURE_IF],
|
||||
[m4_bmatch([$3], [%define *api\.pure\|%pure-parser],
|
||||
[m4_bmatch([$3], [%define *api\.pure *false], [$2], [$1])],
|
||||
[$2])])
|
||||
m4_pushdef([AT_PUSH_IF],
|
||||
[m4_bmatch([$3], [%define api.push-pull \(both\|pull\)], [$1], [$2])])
|
||||
# AT_NAME_PREFIX: also consider api.namespace.
|
||||
m4_pushdef([AT_NAME_PREFIX],
|
||||
[m4_bmatch([$3], [\(%define api\.\(namespace\|prefix\)\|%name-prefix\) .*],
|
||||
@@ -299,6 +301,8 @@ m4_popdef([AT_NAME_PREFIX])
|
||||
m4_popdef([AT_LOCATION_TYPE_IF])
|
||||
m4_popdef([AT_LOCATION_IF])
|
||||
m4_popdef([AT_PARSE_PARAMS])
|
||||
m4_popdef([AT_PUSH_IF])
|
||||
m4_popdef([AT_PURE_IF])
|
||||
m4_popdef([AT_PARAM_IF])
|
||||
m4_popdef([AT_LEXPARAM_IF])
|
||||
m4_popdef([AT_YACC_IF])
|
||||
|
||||
Reference in New Issue
Block a user