Re: [PATCH c/c++] use explicit locations for some warnings in c-pragma.c

2015-11-06 Thread Mike Stump
On Nov 4, 2015, at 1:02 PM, Manuel López-Ibáñez wrote: > On 4 November 2015 at 09:45, Mike Stump wrote: >> in the top of the tree. This is bad as the same line appears in a PASS: and >> an XFAIL:. Each test case should be unique. Should it be updated to 64? > > I think it is sufficient to ch

Re: [PATCH c/c++] use explicit locations for some warnings in c-pragma.c

2015-11-06 Thread Mike Stump
On Nov 4, 2015, at 1:02 PM, Manuel López-Ibáñez wrote: > 24:missing

Re: [PATCH c/c++] use explicit locations for some warnings in c-pragma.c

2015-11-04 Thread Manuel López-Ibáñez
On 4 November 2015 at 09:45, Mike Stump wrote: > in the top of the tree. This is bad as the same line appears in a PASS: and > an XFAIL:. Each test case should be unique. Should it be updated to 64? I think it is sufficient to change it to: /* { dg-warning "24:missing" "wrong column" { xfail

Re: [PATCH c/c++] use explicit locations for some warnings in c-pragma.c

2015-11-04 Thread Mike Stump
On Sep 20, 2015, at 2:40 PM, Manuel López-Ibáñez wrote: > On 20 September 2015 at 22:32, Christophe Lyon > wrote: >> On 25 May 2015 at 22:16, Manuel López-Ibáñez wrote: >>> On 25 May 2015 at 21:56, Marek Polacek wrote: Perhaps we should introduce GCC_BAD_LOC with a location_t argument and

Re: [PATCH c/c++] use explicit locations for some warnings in c-pragma.c

2015-09-21 Thread Manuel López-Ibáñez
On 21 September 2015 at 06:52, Christophe Lyon wrote: > It looks like I mis-applied your patch. > I cleaned up and re-applied it, and I can confirm it fixes the problem. Committed as obvious as r227967. Thanks, Manuel.

Re: [PATCH c/c++] use explicit locations for some warnings in c-pragma.c

2015-09-20 Thread Christophe Lyon
On 21 September 2015 at 02:33, Manuel López-Ibáñez wrote: > On 21 September 2015 at 02:29, Christophe Lyon > wrote: >> On 21 September 2015 at 02:24, Manuel López-Ibáñez >> wrote: >>> On 21 September 2015 at 02:22, Christophe Lyon >>> wrote: It works for me if I replace 24 by 62. >>> >>> W

Re: [PATCH c/c++] use explicit locations for some warnings in c-pragma.c

2015-09-20 Thread Manuel López-Ibáñez
On 21 September 2015 at 02:29, Christophe Lyon wrote: > On 21 September 2015 at 02:24, Manuel López-Ibáñez > wrote: >> On 21 September 2015 at 02:22, Christophe Lyon >> wrote: >>> It works for me if I replace 24 by 62. >> >> Wierd. What is the actual output of the compiler? > > Here is what I ha

Re: [PATCH c/c++] use explicit locations for some warnings in c-pragma.c

2015-09-20 Thread Christophe Lyon
On 21 September 2015 at 02:24, Manuel López-Ibáñez wrote: > On 21 September 2015 at 02:22, Christophe Lyon > wrote: >> It works for me if I replace 24 by 62. > > Wierd. What is the actual output of the compiler? Here is what I have in gcc.log: /home/christophe.lyon/src/GCC/sources/gcc-fsf/trunk/

Re: [PATCH c/c++] use explicit locations for some warnings in c-pragma.c

2015-09-20 Thread Manuel López-Ibáñez
On 21 September 2015 at 02:22, Christophe Lyon wrote: > It works for me if I replace 24 by 62. Wierd. What is the actual output of the compiler?

Re: [PATCH c/c++] use explicit locations for some warnings in c-pragma.c

2015-09-20 Thread Christophe Lyon
On 20 September 2015 at 23:40, Manuel López-Ibáñez wrote: > On 20 September 2015 at 22:32, Christophe Lyon > wrote: >> On 25 May 2015 at 22:16, Manuel López-Ibáñez wrote: >>> On 25 May 2015 at 21:56, Marek Polacek wrote: Perhaps we should introduce GCC_BAD_LOC with a location_t argument an

Re: [PATCH c/c++] use explicit locations for some warnings in c-pragma.c

2015-09-20 Thread Manuel López-Ibáñez
On 20 September 2015 at 22:32, Christophe Lyon wrote: > On 25 May 2015 at 22:16, Manuel López-Ibáñez wrote: >> On 25 May 2015 at 21:56, Marek Polacek wrote: >>> Perhaps we should introduce GCC_BAD_LOC with a location_t argument and use >>> it >>> here. >> >> Why would we want to obfuscate code

Re: [PATCH c/c++] use explicit locations for some warnings in c-pragma.c

2015-09-20 Thread Christophe Lyon
On 25 May 2015 at 22:16, Manuel López-Ibáñez wrote: > On 25 May 2015 at 21:56, Marek Polacek wrote: >> Perhaps we should introduce GCC_BAD_LOC with a location_t argument and use it >> here. > > Why would we want to obfuscate code like that? I would propose to > actually remove GCC_BAD completely.

Re: [PATCH c/c++] use explicit locations for some warnings in c-pragma.c

2015-05-25 Thread Manuel López-Ibáñez
On 25 May 2015 at 21:56, Marek Polacek wrote: > Perhaps we should introduce GCC_BAD_LOC with a location_t argument and use it > here. Why would we want to obfuscate code like that? I would propose to actually remove GCC_BAD completely. Manuel.

Re: [PATCH c/c++] use explicit locations for some warnings in c-pragma.c

2015-05-25 Thread Marek Polacek
On Mon, May 25, 2015 at 06:06:01PM +0200, Manuel López-Ibáñez wrote: >if (token != CPP_NAME) > -GCC_BAD ("missing [error|warning|ignored] after %<#pragma GCC > diagnostic%>"); > +{ > + warning_at (loc, OPT_Wpragmas, > + "missing [error|warning|ignored|push|pop] after

Re: [PATCH c/c++] use explicit locations for some warnings in c-pragma.c

2015-05-25 Thread Jason Merrill
OK. Jason

[PATCH c/c++] use explicit locations for some warnings in c-pragma.c

2015-05-25 Thread Manuel López-Ibáñez
This changes from: pragma-diag-3.c:2:9: warning: missing [error|warning|ignored] after ‘#pragma GCC diagnostic’ [-Wpragmas] #pragma GCC diagnostic /* { dg-warning "24:missing" "missing" { xfail *-*-* } } */ ^ pragma-diag-3.c:4:9: warning: expected [error|warning|ignored|push|pop] after ‘