diff options
author | Basile Starynkevitch <basile@starynkevitch.net> | 2009-11-06 19:20:39 +0000 |
---|---|---|
committer | Rafael Espindola <espindola@gcc.gnu.org> | 2009-11-06 19:20:39 +0000 |
commit | 7ac8318c2daf09b9f2e1612b3add3584f58ac3b7 (patch) | |
tree | 9a9a21a6222d8d5e0d4faa8b2d2a263613b6cd83 /gcc/c-pragma.c | |
parent | 87e928642892922f18f1e652f41d8fc9169ae757 (diff) | |
download | gcc-7ac8318c2daf09b9f2e1612b3add3584f58ac3b7.zip gcc-7ac8318c2daf09b9f2e1612b3add3584f58ac3b7.tar.gz gcc-7ac8318c2daf09b9f2e1612b3add3584f58ac3b7.tar.bz2 |
plugins.texi (Plugin callbacks): added PLUGIN_PRAGMAS.
2009-11-06 Basile Starynkevitch <basile@starynkevitch.net>
* doc/plugins.texi (Plugin callbacks): added PLUGIN_PRAGMAS.
* c-pragma.c: Include "plugin.h".
(init_pragma): Invoke PLUGIN_PRAGMAS.
* gcc-plugin.h: Added PLUGIN_PRAGMAS.
* plugin.c (plugin_event_name): Added PLUGIN_PRAGMAS & the missing
PLUGIN_ATTRIBUTES.
(register_callback): Added PLUGIN_PRAGMAS. Fixed typo in message
error for unknown callback event.
(invoke_plugin_callbacks): Added PLUGIN_PRAGMAS.
* Makefile.in (c-pragma.o): Added dependency upon plugin.h.
(PLUGIN_HEADERS): added plugin.h.
2009-11-06 Basile Starynkevitch <basile@starynkevitch.net>
* g++.dg/plugin/pragma_plugin-test-1.C: new testcase for
PLUGIN_PRAGMAS.
* g++.dg/plugin/pragma_plugin.c: new test plugin for
PLUGIN_PRAGMAS.
* g++.dg/plugin/plugin.exp (plugin_test_list): Add pragma_plugin.c and
pragma_plugin-test-1.C.
From-SVN: r153975
Diffstat (limited to 'gcc/c-pragma.c')
-rw-r--r-- | gcc/c-pragma.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/gcc/c-pragma.c b/gcc/c-pragma.c index f281644..f71399f 100644 --- a/gcc/c-pragma.c +++ b/gcc/c-pragma.c @@ -37,6 +37,7 @@ along with GCC; see the file COPYING3. If not see #include "target.h" #include "diagnostic.h" #include "opts.h" +#include "plugin.h" #define GCC_BAD(gmsgid) \ do { warning (OPT_Wpragmas, gmsgid); return; } while (0) @@ -1450,6 +1451,9 @@ init_pragma (void) #ifdef REGISTER_TARGET_PRAGMAS REGISTER_TARGET_PRAGMAS (); #endif + + /* Allow plugins to register their own pragmas. */ + invoke_plugin_callbacks (PLUGIN_PRAGMAS, NULL); } #include "gt-c-pragma.h" |