diff options
author | jason <jason@138bc75d-0d04-0410-961f-82ee72b054a4> | 2011-06-07 21:52:46 +0000 |
---|---|---|
committer | jason <jason@138bc75d-0d04-0410-961f-82ee72b054a4> | 2011-06-07 21:52:46 +0000 |
commit | 1ea9269b2a4e0073eaef480434e229af491ad327 (patch) | |
tree | cd3370eefb28aa48d04d2f202735041192d37e39 /gcc/pretty-print.h | |
parent | 4173faf53e5b1df73242e6554ca6f5daf6aeaa02 (diff) | |
download | gcc-1ea9269b2a4e0073eaef480434e229af491ad327.tar.gz |
gcc/
* pretty-print.h (ATTRIBUTE_GCC_PPDIAG): Use GCC_DIAG_STYLE if set.
gcc/c-family/
* c-format.c (gcc_cxxdiag_char_table): Add 'S' format.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@174770 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/pretty-print.h')
-rw-r--r-- | gcc/pretty-print.h | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/gcc/pretty-print.h b/gcc/pretty-print.h index 3b6d18e9254..ae1dadfe4a6 100644 --- a/gcc/pretty-print.h +++ b/gcc/pretty-print.h @@ -303,10 +303,18 @@ extern const char *pp_base_last_position_in_text (const pretty_printer *); extern void pp_base_emit_prefix (pretty_printer *); extern void pp_base_append_text (pretty_printer *, const char *, const char *); +/* If we haven't already defined a front-end-specific diagnostics + style, use the generic one. */ +#ifdef GCC_DIAG_STYLE +#define GCC_PPDIAG_STYLE GCC_DIAG_STYLE +#else +#define GCC_PPDIAG_STYLE __gcc_diag__ +#endif + /* This header may be included before diagnostics-core.h, hence the duplicate definitions to allow for GCC-specific formats. */ #if GCC_VERSION >= 3005 -#define ATTRIBUTE_GCC_PPDIAG(m, n) __attribute__ ((__format__ (__gcc_diag__, m ,n))) ATTRIBUTE_NONNULL(m) +#define ATTRIBUTE_GCC_PPDIAG(m, n) __attribute__ ((__format__ (GCC_PPDIAG_STYLE, m ,n))) ATTRIBUTE_NONNULL(m) #else #define ATTRIBUTE_GCC_PPDIAG(m, n) ATTRIBUTE_NONNULL(m) #endif |