bug-bison
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Bison 3.2.90 released [beta]


From: Akim Demaille
Subject: Re: Bison 3.2.90 released [beta]
Date: Mon, 14 Jan 2019 13:47:56 +0100


> Le 13 janv. 2019 à 22:06, Derek Clegg <address@hidden> a écrit :
> 
> Relatively trivial:
> 
> aux/parser-internal.h:767:24: error: extra ';' after member function 
> definition
>      [-Werror,-Wextra-semi]
>      symbol_type () {};
> 
> The fix:
> 
> diff -ur bison-3.2.90/data/skeletons/c++.m4 bison/data/skeletons/c++.m4
> --- bison-3.2.90/data/skeletons/c++.m4        2019-01-05 06:09:28.000000000 
> -0800
> +++ bison/data/skeletons/c++.m4       2019-01-13 13:04:02.000000000 -0800
> @@ -352,7 +352,7 @@
>       typedef basic_symbol<by_type> super_type;
> 
>       /// Empty symbol.
> -      symbol_type () {};
> +      symbol_type () {}
> 
>       /// Constructor for valueless symbols, and symbols from each type.
> ]b4_type_foreach([_b4_token_constructor_define])dnl

Thanks for the report!  I installed this:

commit e17e84d80ccf357aa994f1558841110633e475f3
Author: Akim Demaille <address@hidden>
Date:   Mon Jan 14 08:40:06 2019 +0100

    c++: avoid warnings about extraneous semi-colons
    
    Reported by Derek Clegg.
    http://lists.gnu.org/archive/html/bug-bison/2019-01/msg00005.html
    
    * configure.ac (warn_common): Add -Wextra-semi.
    * data/skeletons/c++.m4: Remove extraneous semi-colon.

diff --git a/configure.ac b/configure.ac
index 7fef652d..20faf8af 100644
--- a/configure.ac
+++ b/configure.ac
@@ -95,7 +95,7 @@ AC_ARG_ENABLE([gcc-warnings],
 AM_CONDITIONAL([ENABLE_GCC_WARNINGS], [test "$enable_gcc_warnings" = yes])
 if test "$enable_gcc_warnings" = yes; then
   warn_common='-Wall -Wextra -Wno-sign-compare -Wcast-align
-    -fparse-all-comments -Wdocumentation
+    -fparse-all-comments -Wdocumentation -Wextra-semi
     -Wformat -Wnull-dereference -Wpointer-arith -Wshadow -Wwrite-strings'
   warn_c='-Wbad-function-cast -Wstrict-prototypes'
   warn_cxx='-Wnoexcept'
diff --git a/data/skeletons/c++.m4 b/data/skeletons/c++.m4
index 137d941b..c985cb98 100644
--- a/data/skeletons/c++.m4
+++ b/data/skeletons/c++.m4
@@ -352,7 +352,7 @@ m4_define([b4_symbol_type_define],
       typedef basic_symbol<by_type> super_type;
 
       /// Empty symbol.
-      symbol_type () {};
+      symbol_type () {}
 
       /// Constructor for valueless symbols, and symbols from each type.
 ]b4_type_foreach([_b4_token_constructor_define])dnl




reply via email to

[Prev in Thread] Current Thread [Next in Thread]