Use explicit locations for some warnings in c-pragma.c.
authorManuel López-Ibáñez <manu@gcc.gnu.org>
Fri, 18 Sep 2015 19:36:19 +0000 (19:36 +0000)
committerManuel López-Ibáñez <manu@gcc.gnu.org>
Fri, 18 Sep 2015 19:36:19 +0000 (19:36 +0000)
commitc4914de6185a913d2dbb152a15b0c43b9d70106c
tree616fcade21d35e7c06e245ee5b7578f95ca8ad86
parentedfc92491b22d1cd8f5fc1101cc148cc85f49441
Use explicit locations for some warnings in c-pragma.c.

gcc/cp/ChangeLog:

2015-09-18  Manuel López-Ibáñez  <manu@gcc.gnu.org>

* parser.c (pragma_lex): Add loc argument. Rearrange the code to
make it more similar to the C version.

gcc/c-family/ChangeLog:

2015-09-18  Manuel López-Ibáñez  <manu@gcc.gnu.org>

* c-pragma.c (handle_pragma_diagnostic): Use explicit location
when warning.
* c-pragma.h (pragma_lex): Add optional loc argument.

gcc/c/ChangeLog:

2015-09-18  Manuel López-Ibáñez  <manu@gcc.gnu.org>

* c-parser.c (pragma_lex): Add loc argument.

gcc/testsuite/ChangeLog:

2015-09-18  Manuel López-Ibáñez  <manu@gcc.gnu.org>

* gcc.dg/pragma-diag-5.c: New test.

From-SVN: r227923
gcc/c-family/ChangeLog
gcc/c-family/c-pragma.c
gcc/c-family/c-pragma.h
gcc/c/ChangeLog
gcc/c/c-parser.c
gcc/cp/ChangeLog
gcc/cp/parser.c
gcc/testsuite/ChangeLog
gcc/testsuite/gcc.dg/pragma-diag-5.c [new file with mode: 0644]