diff options
author | Douglas Gregor <dgregor@apple.com> | 2015-07-07 03:58:42 +0000 |
---|---|---|
committer | Douglas Gregor <dgregor@apple.com> | 2015-07-07 03:58:42 +0000 |
commit | ab209d83be5dadff4f17364a71f323b89e3c63f8 (patch) | |
tree | 5e97315685c9476095deef062e53e98e525d78e5 /clang/lib/Lex/PPMacroExpansion.cpp | |
parent | 10dc9d80cbb47675be0c6ea8481e12ec197e1637 (diff) | |
download | bcm5719-llvm-ab209d83be5dadff4f17364a71f323b89e3c63f8.tar.gz bcm5719-llvm-ab209d83be5dadff4f17364a71f323b89e3c63f8.zip |
Implement the Objective-C __kindof type qualifier.
The __kindof type qualifier can be applied to Objective-C object
(pointer) types to indicate id-like behavior, which includes implicit
"downcasting" of __kindof types to subclasses and id-like message-send
behavior. __kindof types provide better type bounds for substitutions
into unspecified generic types, which preserves more type information.
llvm-svn: 241548
Diffstat (limited to 'clang/lib/Lex/PPMacroExpansion.cpp')
-rw-r--r-- | clang/lib/Lex/PPMacroExpansion.cpp | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/clang/lib/Lex/PPMacroExpansion.cpp b/clang/lib/Lex/PPMacroExpansion.cpp index 0fb4456790e..6790908fe4b 100644 --- a/clang/lib/Lex/PPMacroExpansion.cpp +++ b/clang/lib/Lex/PPMacroExpansion.cpp @@ -1088,6 +1088,7 @@ static bool HasFeature(const Preprocessor &PP, const IdentifierInfo *II) { .Case("objc_default_synthesize_properties", LangOpts.ObjC2) .Case("objc_fixed_enum", LangOpts.ObjC2) .Case("objc_instancetype", LangOpts.ObjC2) + .Case("objc_kindof", LangOpts.ObjC2) .Case("objc_modules", LangOpts.ObjC2 && LangOpts.Modules) .Case("objc_nonfragile_abi", LangOpts.ObjCRuntime.isNonFragile()) .Case("objc_property_explicit_atomic", |