diff options
author | Michael Meissner <meissner@linux.vnet.ibm.com> | 2011-03-21 16:21:30 +0000 |
---|---|---|
committer | Michael Meissner <meissner@gcc.gnu.org> | 2011-03-21 16:21:30 +0000 |
commit | f3c33d9dc88ca9b2452a9ea3d42d9a6363b66663 (patch) | |
tree | a11038042e07218234e45c1da1c876bdbdf8c2d5 /libcpp/expr.c | |
parent | ac43f774369194320ba2368b21550d4aa5ca97b9 (diff) | |
download | gcc-f3c33d9dc88ca9b2452a9ea3d42d9a6363b66663.tar.gz |
Make UNSPEC/UNSPECV constants use the enum; Fix 48192; Add test case for 48053
From-SVN: r171247
Diffstat (limited to 'libcpp/expr.c')
-rw-r--r-- | libcpp/expr.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/libcpp/expr.c b/libcpp/expr.c index d2fec2a56a6..3c36127b54f 100644 --- a/libcpp/expr.c +++ b/libcpp/expr.c @@ -720,10 +720,15 @@ parse_defined (cpp_reader *pfile) pfile->state.prevent_expansion--; + /* Do not treat conditional macros as being defined. This is due to the + powerpc and spu ports using conditional macros for 'vector', 'bool', and + 'pixel' to act as conditional keywords. This messes up tests like #ifndef + bool. */ result.unsignedp = false; result.high = 0; result.overflow = false; - result.low = node && node->type == NT_MACRO; + result.low = (node && node->type == NT_MACRO + && (node->flags & NODE_CONDITIONAL) == 0); return result; } |