Re: [PATCH] warnings: Add gl_WARN_COMPLEMENT and gl_WARN_SUPPORTED.

2008-12-09 Thread Eric Blake
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 According to Bruno Haible on 12/8/2008 4:07 PM: > Before doing that, I'd like to see the results that Simon, Jim, Eric, and > others get on reasonably large code bases. My list of warnings to avoid > is certainly biased. What we document in the manual

Re: [PATCH] warnings: Add gl_WARN_COMPLEMENT and gl_WARN_SUPPORTED.

2008-12-09 Thread Pádraig Brady
Bruno Haible wrote: > > The list of warnings that I would disable unconditionally would be: > > warnings="$warnings -Wno-sign-compare" # These warnings usually don't > point to mistakes. Usually -Wsign-compare warnings don't point to mistakes, but they can point to non obvious mistakes (whi

Re: [PATCH] warnings: Add gl_WARN_COMPLEMENT and gl_WARN_SUPPORTED.

2008-12-08 Thread Bruno Haible
Karl Berry wrote: > Wow, that is a great list. A lot of it does not seem gettext-specific? Yes, probably 80% of that list can also be disabled on other C packages. > Maybe it would be worth putting the description of all these warnings > you have researched into the manual? Before doing that, I

Re: [PATCH] warnings: Add gl_WARN_COMPLEMENT and gl_WARN_SUPPORTED.

2008-12-08 Thread Karl Berry
The list of warnings that I would disable unconditionally would be: Wow, that is a great list. A lot of it does not seem gettext-specific? Maybe it would be worth putting the description of all these warnings you have researched into the manual? Thanks, karl

Re: [PATCH] warnings: Add gl_WARN_COMPLEMENT and gl_WARN_SUPPORTED.

2008-12-07 Thread Bruno Haible
Simon Josefsson wrote: > I guess the effort is to document for each warning variable > the code snippet that triggers it, and discuss whether it is a common > warning and how useful it is. > > > The reasonable set that I recommend is "-Wall". > > I'd like to be able to add more to that list, to h

Re: [PATCH] warnings: Add gl_WARN_COMPLEMENT and gl_WARN_SUPPORTED.

2008-12-07 Thread Ralf Wildenhues
Hello Bruno, a couple of typo nits: * Bruno Haible wrote on Sat, Dec 06, 2008 at 12:17:07PM CET: > doc/manywarnings.texi > > @node manywarnings > @section manywarnings > > The @code{manywarnings} module allows you to enable as many GCC w

Re: [PATCH] warnings: Add gl_WARN_COMPLEMENT and gl_WARN_SUPPORTED.

2008-12-06 Thread Bruno Haible
Simon Josefsson wrote on 2008-11-18: > I'm trying to force gradual automation of it by making it a two-step > simple process: 1) Sync the list of all warnings with latest GCC > manual. 2) Re-compile and add exceptions for the new warning variables, > and if optionally human time is available, revie

Re: [PATCH] warnings: Add gl_WARN_COMPLEMENT and gl_WARN_SUPPORTED.

2008-11-18 Thread Simon Josefsson
Brian Dessent <[EMAIL PROTECTED]> writes: > Simon Josefsson wrote: > >> +# gl_MANYWARN_ALL_GCC(VARIABLE) >> +# - >> +# Add all documented GCC (currently as per version 4.3.2) warning >> +# parameters to variable VARIABLE. Note that you need to test them >> +# using gl_

Re: [PATCH] warnings: Add gl_WARN_COMPLEMENT and gl_WARN_SUPPORTED.

2008-11-18 Thread Brian Dessent
Simon Josefsson wrote: > +# gl_MANYWARN_ALL_GCC(VARIABLE) > +# - > +# Add all documented GCC (currently as per version 4.3.2) warning > +# parameters to variable VARIABLE. Note that you need to test them > +# using gl_WARN_ADD if you want to make sure your gcc understa

Re: [PATCH] warnings: Add gl_WARN_COMPLEMENT and gl_WARN_SUPPORTED.

2008-11-18 Thread Simon Josefsson
Bruno Haible <[EMAIL PROTECTED]> writes: > Simon Josefsson wrote: >> I'm preparing a blog post about gcc warnings, but briefly my idea with >> warnings.m4 is to enable all possible warnings, build your project once >> with -Werror, disable the warnings that cause problems (using >> gl_WARN_COMPLEM

Re: [PATCH] warnings: Add gl_WARN_COMPLEMENT and gl_WARN_SUPPORTED.

2008-11-18 Thread Bruno Haible
Simon Josefsson wrote: > I'm preparing a blog post about gcc warnings, but briefly my idea with > warnings.m4 is to enable all possible warnings, build your project once > with -Werror, disable the warnings that cause problems (using > gl_WARN_COMPLEMENT), and set up so that the maintainer always b

Re: [PATCH] warnings: Add gl_WARN_COMPLEMENT and gl_WARN_SUPPORTED.

2008-11-18 Thread Simon Josefsson
Bruno Haible <[EMAIL PROTECTED]> writes: > Hi Simon, > > What is the use of these macros gl_WARN_COMPLEMENT, gl_WARN_SUPPORTED? > They are not documented, and you haven't said what they are good for. I'm using them in some packages like this: http://git.savannah.gnu.org/gitweb/?p=gnutls.git;a=bl

Re: [PATCH] warnings: Add gl_WARN_COMPLEMENT and gl_WARN_SUPPORTED.

2008-11-18 Thread Bruno Haible
Hi Simon, What is the use of these macros gl_WARN_COMPLEMENT, gl_WARN_SUPPORTED? They are not documented, and you haven't said what they are good for. In particular, I don't see what anyone can do with the list of all GCC supported warning options. While -Wall is widely applicable, most other war

Re: [PATCH] warnings: Add gl_WARN_COMPLEMENT and gl_WARN_SUPPORTED.

2008-11-17 Thread Paolo Bonzini
Ralf Wildenhues wrote: > * Paolo Bonzini wrote on Mon, Nov 17, 2008 at 10:42:24PM CET: >> Forgot one: >> >> for w in "$@"; do > > No. You *really* want > for w > do > > as I wrote already. Right, I hadn't seen your message, sorry. Paolo

Re: [PATCH] warnings: Add gl_WARN_COMPLEMENT and gl_WARN_SUPPORTED.

2008-11-17 Thread Ralf Wildenhues
* Paolo Bonzini wrote on Mon, Nov 17, 2008 at 10:42:24PM CET: > Forgot one: > > for w in "$@"; do No. You *really* want for w do as I wrote already. This is all documented in autoconf.info. Cheers, Ralf

Re: [PATCH] warnings: Add gl_WARN_COMPLEMENT and gl_WARN_SUPPORTED.

2008-11-17 Thread Paolo Bonzini
Paolo Bonzini wrote: >> +# does OUTVAR = LISTVAR \ REMOVEVAR. >> +AC_DEFUN([gl_WARN_COMPLEMENT], >> +[ >> + FOO= > > FOO? gl_new_list at the very least. > >> + set -- "$2" > > set args $2; shift > >> + for w in $_; do Forgot one: for w in "$@"; do >> +case "$3" in >> + *" $w "* |

Re: [PATCH] warnings: Add gl_WARN_COMPLEMENT and gl_WARN_SUPPORTED.

2008-11-17 Thread Simon Josefsson
Ralf Wildenhues <[EMAIL PROTECTED]> writes: Paolo Bonzini <[EMAIL PROTECTED]> writes: ... Thanks for feedback. I've pushed this. /Simon >From ceb6e31c70e82abcb29c58c429683dd89969935b Mon Sep 17 00:00:00 2001 From: Simon Josefsson <[EMAIL PROTECTED]> Date: Mon, 17 Nov 2008 22:11:30 +0100 Subjec

Re: [PATCH] warnings: Add gl_WARN_COMPLEMENT and gl_WARN_SUPPORTED.

2008-11-17 Thread Paolo Bonzini
> +# does OUTVAR = LISTVAR \ REMOVEVAR. > +AC_DEFUN([gl_WARN_COMPLEMENT], > +[ > + FOO= FOO? gl_new_list at the very least. > + set -- "$2" set args $2; shift > + for w in $_; do > +case "$3" in > + *" $w "* | *" $w" | "$w "*) case " $3 " in *" $w "*) ;; Paolo

Re: [PATCH] warnings: Add gl_WARN_COMPLEMENT and gl_WARN_SUPPORTED.

2008-11-17 Thread Ralf Wildenhues
Hi Simon, * Simon Josefsson wrote on Mon, Nov 17, 2008 at 05:45:46PM CET: > +AC_DEFUN([gl_WARN_COMPLEMENT], > +[ > + FOO= > + set -- "$2" 'set --' is told to not be fully portable. Why don't you allow word-splitting $2 here, so that ... > + for w in $_; do ... here, you don't have to use un

Re: [PATCH] warnings: Add gl_WARN_COMPLEMENT and gl_WARN_SUPPORTED.

2008-11-17 Thread Simon Josefsson
Follow-up fix. /Simon >From c23fafe9a03c4216789d09d65224d9200d528026 Mon Sep 17 00:00:00 2001 From: Simon Josefsson <[EMAIL PROTECTED]> Date: Mon, 17 Nov 2008 18:17:11 +0100 Subject: [PATCH] Fix last commit. --- m4/warnings.m4 |7 --- 1 files changed, 4 insertions(+), 3 deletions(-) di

[PATCH] warnings: Add gl_WARN_COMPLEMENT and gl_WARN_SUPPORTED.

2008-11-17 Thread Simon Josefsson
Pushed. /Simon --- ChangeLog |4 ++ m4/warnings.m4 | 84 2 files changed, 88 insertions(+), 0 deletions(-) diff --git a/ChangeLog b/ChangeLog index b5a87b2..0d3139c 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,7 @@ +2008-1