bug-tar
[Top][All Lists]
Advanced

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

Re: [Bug-tar] GCC 7 warnings


From: Paul Eggert
Subject: Re: [Bug-tar] GCC 7 warnings
Date: Fri, 8 Sep 2017 08:10:02 -0700
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.2.1

Pavel Raiskup wrote:
On Friday, September 8, 2017 12:06:22 PM CEST Sergey Poznyakoff wrote:
Paul Eggert <address@hidden> ha escrit:

I suggest ignoring the warning globally by pragma (i.e., in
configure.ac) since it's more trouble than it's worth for tar.

Agreed.

Please have a look at the attached patch then.

+  nw="$nw -Wformat-overflow=2"

This part looks fine, and I suggest installing it as a separate patch.

+  gl_WARN_ADD([-Wimplicit-fallthrough=1]) # Be more tolerant to fall-through 
comments

Instead of this, I suggest doing what Gnulib does:

# if __GNUC__ < 7
#  define FALLTHROUGH ((void) 0)
# else
#  define FALLTHROUGH __attribute__ ((__fallthrough__))
# endif

and then use 'FALLTHROUGH;' instead of comments.



reply via email to

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