From ff9eee58c337b0a7f90736d738691fe235480fef Mon Sep 17 00:00:00 2001 From: Paul Eggert Date: Tue, 21 Jul 2026 08:13:23 -0700 Subject: [PATCH] bison: port to GCC 16.1.1 -Wmaybe-uninitialized * data/skeletons/lalr1.cc: Increase the scope of YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN. Needed for GCC 16.1.1 20260515 (Red Hat 16.1.1-2). --- data/skeletons/lalr1.cc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/data/skeletons/lalr1.cc b/data/skeletons/lalr1.cc index 11dcd37e..c0f6a066 100644 --- a/data/skeletons/lalr1.cc +++ b/data/skeletons/lalr1.cc @@ -843,6 +843,7 @@ m4_if(b4_prefix, [yy], [], int ]b4_parser_class[::parse () { + YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN int yyn; /// Length of the RHS of the rule being reduced. int yylen = 0; @@ -987,7 +988,6 @@ b4_dollar_popdef])[]dnl yyreduce: yylen = yyr2_[yyn]; { - YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN stack_symbol_type yylhs; yylhs.state = yy_lr_goto_state_ (yystack_[yylen].state, yyr1_[yyn]);]b4_variant_if([[ /* Variants are always initialized to an empty instance of the @@ -1040,7 +1040,6 @@ b4_dollar_popdef])[]dnl // Shift the result of the reduction. yypush_ (YY_NULLPTR, YY_MOVE (yylhs)); - YY_IGNORE_MAYBE_UNINITIALIZED_END } goto yynewstate; @@ -1181,6 +1180,7 @@ b4_dollar_popdef])[]dnl } return yyresult; + YY_IGNORE_MAYBE_UNINITIALIZED_END } #if YY_EXCEPTIONS catch (...)