aboutsummaryrefslogtreecommitdiff
path: root/lib/Lex/PPMacroExpansion.cpp
diff options
context:
space:
mode:
authorJohn McCall <rjmccall@apple.com>2012-06-20 21:58:02 +0000
committerJohn McCall <rjmccall@apple.com>2012-06-20 21:58:02 +0000
commit0b92fcb1353d2d8b31b6c485e6caa14568aca43b (patch)
tree3026711a737a0db3164592f467792fbb4a4aea01 /lib/Lex/PPMacroExpansion.cpp
parenta6366f5c7e92466ebad0042afa55c2e5952ebe61 (diff)
Introduce ObjCRuntime::hasWeakClassImport() and use it in the appropriate
places. I've turned this off for the GNU runtimes --- I don't know if they support weak class import, but it's easy enough for them to opt in. Also tweak a comment per review by Jordan. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@158860 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Lex/PPMacroExpansion.cpp')
-rw-r--r--lib/Lex/PPMacroExpansion.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/Lex/PPMacroExpansion.cpp b/lib/Lex/PPMacroExpansion.cpp
index 826fa03621..a5337867b1 100644
--- a/lib/Lex/PPMacroExpansion.cpp
+++ b/lib/Lex/PPMacroExpansion.cpp
@@ -644,7 +644,7 @@ static bool HasFeature(const Preprocessor &PP, const IdentifierInfo *II) {
.Case("objc_instancetype", LangOpts.ObjC2)
.Case("objc_modules", LangOpts.ObjC2 && LangOpts.Modules)
.Case("objc_nonfragile_abi", LangOpts.ObjCRuntime.isNonFragile())
- .Case("objc_weak_class", LangOpts.ObjCRuntime.isNonFragile())
+ .Case("objc_weak_class", LangOpts.ObjCRuntime.hasWeakClassImport())
.Case("ownership_holds", true)
.Case("ownership_returns", true)
.Case("ownership_takes", true)