This is the mail archive of the
mailing list for the glibc project.
Re: Add macros for diagnostic control, use them in locale/weightwc.h
- From: Joseph Myers <joseph at codesourcery dot com>
- To: Paul Eggert <eggert at cs dot ucla dot edu>
- Cc: <libc-alpha at sourceware dot org>
- Date: Fri, 21 Nov 2014 18:27:45 +0000
- Subject: Re: Add macros for diagnostic control, use them in locale/weightwc.h
- Authentication-results: sourceware.org; auth=none
- References: <alpine dot DEB dot 2 dot 10 dot 1411181803130 dot 11642 at digraph dot polyomino dot org dot uk> <546BB1B1 dot 50000 at cs dot ucla dot edu> <alpine dot DEB dot 2 dot 10 dot 1411182256130 dot 18922 at digraph dot polyomino dot org dot uk> <546BDAF1 dot 8070401 at cs dot ucla dot edu> <alpine dot DEB dot 2 dot 10 dot 1411182357390 dot 18922 at digraph dot polyomino dot org dot uk> <546C3DF5 dot 3030308 at cs dot ucla dot edu> <alpine dot DEB dot 2 dot 10 dot 1411191455100 dot 28145 at digraph dot polyomino dot org dot uk> <546F7662 dot 4060109 at cs dot ucla dot edu>
On Fri, 21 Nov 2014, Paul Eggert wrote:
> Joseph Myers wrote:
> > The point is it's something you can grep for so that only a subset of the
> > diagnostic disabling needs checking each time the minimum GCC version
> > increases.
> This worries me, because it implies these macros will be so commonly used that
> the cost in adding (and more importantly, having developers read) GCC version
> numbers every time the macros are used is worth the benefit of checking only a
> subset of the uses once in a blue moon. If these macros are rarely used, the
> version numbers won't help much; and if the macros are used often I expect we
> will have so many other problems that the version numbers won't help much.
Even with a few uses, it's still helpful to be able to check for new GCC
versions incrementally rather than requiring all the checks for all pragma
uses to be done at once, or the state of which have been checked to be
tracked externally - as soon as there are pragmas for warnings seen on
multiple architectures, it may not be convenient for the person increasing
the required GCC version to check whether all the warnings are still
applicable, and so the version numbers mean the state of the partial
transition is visible in the source tree.
Joseph S. Myers