re PR preprocessor/57580 (Repeated _Pragma message directives in macro causes problems)
authorJakub Jelinek <jakub@redhat.com>
Wed, 2 Dec 2015 23:53:43 +0000 (00:53 +0100)
committerJakub Jelinek <jakub@gcc.gnu.org>
Wed, 2 Dec 2015 23:53:43 +0000 (00:53 +0100)
commit6eb4a537637cea8691f76bde57a4bf210489b3fd
tree0f7a15c341c498470e6d34e8e39ac7c67506448f
parent49ed2fa42911fe38392f2667fee04df0bd1191f9
re PR preprocessor/57580 (Repeated _Pragma message directives in macro causes problems)

PR preprocessor/57580
* c-ppoutput.c (print): Change printed field to bool.
Move src_file last for smaller padding.
(init_pp_output): Set print.printed to false instead of 0.
(scan_translation_unit): Fix up formatting.  Set print.printed
to true after printing something other than newline.
(scan_translation_unit_trad): Set print.printed to true instead of 1.
(maybe_print_line_1): Set print.printed to false instead of 0.
(print_line_1): Likewise.
(do_line_change): Set print.printed to true instead of 1.
(cb_define, dump_queued_macros, cb_include, cb_def_pragma,
dump_macro): Set print.printed to false after printing newline.

* c-c++-common/cpp/pr57580.c: New test.
* c-c++-common/gomp/pr57580.c: New test.

From-SVN: r231213
gcc/c-family/ChangeLog
gcc/c-family/c-ppoutput.c
gcc/testsuite/ChangeLog
gcc/testsuite/c-c++-common/cpp/pr57580.c [new file with mode: 0644]
gcc/testsuite/c-c++-common/gomp/pr57580.c [new file with mode: 0644]