This is the mail archive of the
mailing list for the GCC project.
Re: [Patch to gcc/function] PR 58362
- From: Paolo Carlini <paolo dot carlini at oracle dot com>
- To: Richard Biener <rguenther at suse dot de>
- Cc: "gcc-patches at gcc dot gnu dot org" <gcc-patches at gcc dot gnu dot org>, Jan Hubicka <hubicka at ucw dot cz>
- Date: Mon, 09 Sep 2013 12:38:46 +0200
- Subject: Re: [Patch to gcc/function] PR 58362
- Authentication-results: sourceware.org; auth=none
- References: <522CCF1B dot 8080007 at oracle dot com> <alpine dot LNX dot 2 dot 00 dot 1309090945470 dot 3869 at zhemvz dot fhfr dot qr> <522D8BBC dot 608 at oracle dot com> <alpine dot LNX dot 2 dot 00 dot 1309091132340 dot 3869 at zhemvz dot fhfr dot qr> <alpine dot LNX dot 2 dot 00 dot 1309091136460 dot 3869 at zhemvz dot fhfr dot qr>
On 09/09/2013 11:37 AM, Richard Biener wrote:
If the decl is *not* a PARM_DECL, I expect %q+D to be often accurate. In
fact, even when *is* a PARM_DECL what we have now is pretty decent,
because normally the location of the corresponding FUNCTION_DECL isn't
that far. The point is whether we want to be *more* accurate and point
to the specific unused parameter, for C and C++, as clang and icc do.
That said, grepping for %q+D reveals quite some uses and it looks like
all of them expect the location being used to be that of the decl passed
to the diagnostic call, not some random other location.