* c-ppoutput.c (scan_translation_unit): Handle CPP_PRAGMA
authorjakub <jakub@138bc75d-0d04-0410-961f-82ee72b054a4>
Wed, 27 Feb 2008 08:51:22 +0000 (08:51 +0000)
committerjakub <jakub@138bc75d-0d04-0410-961f-82ee72b054a4>
Wed, 27 Feb 2008 08:51:22 +0000 (08:51 +0000)
commit146a43087bfa89b2883b112b048d5d8eee86b1dd
tree8f08c19e97ef9a3849f6682bc5e7ccb5dbe60947
parenta81f136fe2c8dccfa9bd074292a3b6643164d2b7
* c-ppoutput.c (scan_translation_unit): Handle CPP_PRAGMA
and CPP_PRAGMA_EOL.
* c-pragma.c (pragma_ns_name): New typedef.
(registered_pp_pragmas): New variable.
(c_pp_lookup_pragma): New function.
(c_register_pragma_1): If flag_preprocess_only, do nothing
for non-expanded pragmas, for expanded ones push pragma's
namespace and name into registered_pp_pragmas vector.
(c_invoke_pragma_handler): Register OpenMP pragmas even when
flag_preprocess_only, don't register GCC pch_preprocess
pragma if flag_preprocess_only.
* c-opts.c (c_common_init): Call init_pragma even if
flag_preprocess_only.
* c-pragma.c (c_pp_lookup_pragma): New prototype.
* config/darwin.h (DARWIN_REGISTER_TARGET_PRAGMAS): Don't call
cpp_register_pragma if flag_preprocess_only.

* gcc.dg/gomp/preprocess-1.c: New test.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@132703 138bc75d-0d04-0410-961f-82ee72b054a4
gcc/ChangeLog
gcc/c-opts.c
gcc/c-ppoutput.c
gcc/c-pragma.c
gcc/c-pragma.h
gcc/config/darwin.h
gcc/testsuite/ChangeLog
gcc/testsuite/gcc.dg/gomp/preprocess-1.c [new file with mode: 0644]