This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH] Make -Wcoverage-mismatch behavior sane.
- From: Jan Hubicka <hubicka at ucw dot cz>
- To: Neil Vachharajani <nvachhar at google dot com>
- Cc: Manuel López-Ibá?ez <lopezibanez at gmail dot com>, gcc-patches at gcc dot gnu dot org, jh at suse dot cz
- Date: Tue, 4 May 2010 19:47:33 +0200
- Subject: Re: [PATCH] Make -Wcoverage-mismatch behavior sane.
- References: <v2pb3d309911004281924md62e68fak921b029e9cb247f@mail.gmail.com> <h2r6c33472e1004290052x8be13e7alab1f392efeaa155b@mail.gmail.com> <y2vb3d309911004290929p7e6133c8yfa97e185f326cdc1@mail.gmail.com> <o2h6c33472e1004291018z1e37a207ub7d2e92f24e7ccbe@mail.gmail.com> <s2vb3d309911004291212va65fc14bsee2bf066b6bed3d3@mail.gmail.com>
> > Index: gcc/diagnostic.h
> > ===================================================================
> > --- gcc/diagnostic.h ? ?(revision 158822)
> > +++ gcc/diagnostic.h ? ?(working copy)
> > @@ -215,6 +215,12 @@
> > ?extern diagnostic_t diagnostic_classify_diagnostic (diagnostic_context *,
> > ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ?int /* optidx */,
> > ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ?diagnostic_t /* kind */);
> > +static inline diagnostic_t
> > +diagnostic_kind (diagnostic_context *context, int option_index)
> > +{
> > + ? ?return context->classify_diagnostic[option_index];
> > +}
> > +
> > ?extern bool diagnostic_report_diagnostic (diagnostic_context *,
> > ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ?diagnostic_info *);
> > ?#ifdef ATTRIBUTE_GCC_DIAG
> >
> >
> > I am not saying that you need to do this, you should wait until a
> > maintainer decides about the patch.
>
> Sounds good. We'll wait to here from Jan.
The patch is OK. In a way I would prefer with the mismatch warning disabled still output
an inform (i.e. it is good to know what particular file is mismatching) but I guess others
might have different preferrences and the patch definitly improve the current situation.
Honza
/bin/bash: ./:q: Permission denied
> Neil
>
> >
> > Cheers,
> >
> > Manuel.
>
>
>
> --
> Neil Vachharajani
> Google
> 650-214-1804