Re: diffseq: Silence gcc warning

2023-05-27 Thread Paul Eggert
On 2023-05-27 09:25, Bruno Haible wrote: For 30 years, "gcc -Wall" has been and is the best recipe for getting meaningful warnings across packages. It's not like a "random compiler". It can be a random compiler if you use GCC the wrong way. If you use an old version of GCC it might generate bo

Re: diffseq: Silence gcc warning

2023-05-27 Thread Bruno Haible
Paul Eggert wrote: > >$ ../configure CC=gcc CXX=g++ CPPFLAGS=-Wall 2>&1 | tee log1 > > Oh, that enables warnings (i.e., it looks for lint), but it is not > compiling with -DGCC_LINT. It enables warnings, because in my experience '-Wall' is a good recipe across packages (except for -Wstringop

Re: diffseq: Silence gcc warning

2023-05-27 Thread Paul Eggert
On 2023-05-27 02:39, Bruno Haible wrote: $ ../configure CC=gcc CXX=g++ CPPFLAGS=-Wall 2>&1 | tee log1 Oh, that enables warnings (i.e., it looks for lint), but it is not compiling with -DGCC_LINT. In general we don't need to support that combination, any more than we need to support lint ch

Re: diffseq: Silence gcc warning

2023-05-27 Thread Bruno Haible
Paul Eggert wrote: > > diffseq.h:424:36: warning: 'fxbest' may be used uninitialized > > [-Wmaybe-uninitialized] > > diffseq.h:431:36: warning: 'bxbest' may be used uninitialized > > [-Wmaybe-uninitialized] > > What platform are you using and how did you configure and build? To reproduce with g

Re: diffseq: Silence gcc warning

2023-05-26 Thread Paul Eggert
On 2023-05-26 05:56, Bruno Haible wrote: In gettext and diffutils, I'm still seeing these warnings: diffseq.h:424:36: warning: 'fxbest' may be used uninitialized [-Wmaybe-uninitialized] diffseq.h:431:36: warning: 'bxbest' may be used uninitialized [-Wmaybe-uninitialized] I don't get that war

Re: diffseq: Silence gcc warning

2023-05-26 Thread Bruno Haible
> 2023-05-26 Bruno Haible > > diffseq: Silence gcc warning. > * lib/diffseq.h: Add #pragma GCC diagnostic. Oops, this patch was not sufficient. With gcc 13.1.0 I see this warning: diffseq.h:561:20: warning: 'part.xmid' may be used uninitialized [-Wmayb

diffseq: Silence gcc warning

2023-05-26 Thread Bruno Haible
runo Haible diffseq: Silence gcc warning. * lib/diffseq.h: Add #pragma GCC diagnostic. diff --git a/lib/diffseq.h b/lib/diffseq.h index c9375cd696..bab8256f64 100644 --- a/lib/diffseq.h +++ b/lib/diffseq.h @@ -94,11 +94,17 @@ /* Use this to suppress gcc's "...