summaryrefslogtreecommitdiffstats
path: root/clang/lib/Lex/Preprocessor.cpp
diff options
context:
space:
mode:
authorSteve Naroff <snaroff@apple.com>2008-05-15 21:12:10 +0000
committerSteve Naroff <snaroff@apple.com>2008-05-15 21:12:10 +0000
commitad91868aa60740bd834a1c98a7f2440bd06fde1b (patch)
treecc7c02adaad2e2eaac97faebafb01ef3034eadee /clang/lib/Lex/Preprocessor.cpp
parent6ef726a06690c96f647d07510fc3eddd27b260b0 (diff)
downloadbcm5719-llvm-ad91868aa60740bd834a1c98a7f2440bd06fde1b.tar.gz
bcm5719-llvm-ad91868aa60740bd834a1c98a7f2440bd06fde1b.zip
Fix rewriter bug <rdar://problem/5929344> clang ObjC rewriter: "extern int __CFConstantStringClassReference[];" should be extern "C".
Have clang predefine OBJC_NEW_PROPERTIES (which is what gcc does). llvm-svn: 51163
Diffstat (limited to 'clang/lib/Lex/Preprocessor.cpp')
-rw-r--r--clang/lib/Lex/Preprocessor.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/clang/lib/Lex/Preprocessor.cpp b/clang/lib/Lex/Preprocessor.cpp
index ccc9a8781ff..8dac3f066fa 100644
--- a/clang/lib/Lex/Preprocessor.cpp
+++ b/clang/lib/Lex/Preprocessor.cpp
@@ -402,6 +402,8 @@ static void InitializePredefinedMacros(Preprocessor &PP,
DefineBuiltinMacro(Buf, "__STDC_HOSTED__=1");
if (PP.getLangOptions().ObjC1)
DefineBuiltinMacro(Buf, "__OBJC__=1");
+ if (PP.getLangOptions().ObjC2)
+ DefineBuiltinMacro(Buf, "OBJC_NEW_PROPERTIES");
// Add __builtin_va_list typedef.
{
OpenPOWER on IntegriCloud