On 21 February 2017 at 15:05, Bruno Haible <[email protected]> wrote:

> Hi Reuben,
>
> > ​For example, would it be sensible to have a single spec file, with each
> > row as follows:
> >
> > warning language-list comment
> >
> > i.e. the first and third columns as at present, and the second giving the
> > languages for which the flag is used?
>
> In my opinion
>
> 1) How to specify the set of options to avoid is orthogonal to the C vs C++
>    consideration.
>

Sorry, I think I confused things, I should have said "the second giving the
list of languages for which the flag is [explicitly] disabled".

2) I find the usage approach from
>    https://www.gnu.org/software/gnulib/manual/html_node/manywarnings.html
>    to be just as easy to use as a .spec file, and furthermore it is more
>    flexible:
>    - It allows to use different sets of warnings for clang than for gcc
>      (remember that clang disguises as gcc). You need a line such as
>        CC_BRAND=`LC_ALL=C $CC --version | sed -e '2,$d' -e 's/ .*//'` #
> either gcc or clang
>      to distinguish them.
>    - It allows multiline descriptions why a warning is avoided.
>

​I agree, I use this approach. Maybe I misunderstood what the specfile is
for: I thought it was a way to generate and check the list of ​warning
flags to go in manywarnings.m4, not something one would directly use in a
project.

-- 
http://rrt.sc3d.org

Reply via email to