aboutsummaryrefslogtreecommitdiff
path: root/clang/lib/Sema/SemaCodeComplete.cpp
diff options
context:
space:
mode:
authorDouglas Gregor <dgregor@apple.com>2015-07-07 03:57:15 +0000
committerDouglas Gregor <dgregor@apple.com>2015-07-07 03:57:15 +0000
commit85f3f9513dbc88b9898d022a1a55a03d55612721 (patch)
tree45a1588a19cd825ecbd1301074a3f9cc06c1a003 /clang/lib/Sema/SemaCodeComplete.cpp
parent27467eab812b0aa85515ae0d6bcce2e41d098f35 (diff)
downloadllvm-85f3f9513dbc88b9898d022a1a55a03d55612721.zip
llvm-85f3f9513dbc88b9898d022a1a55a03d55612721.tar.gz
llvm-85f3f9513dbc88b9898d022a1a55a03d55612721.tar.bz2
Parsing, semantic analysis, and AST for Objective-C type parameters.
Produce type parameter declarations for Objective-C type parameters, and attach lists of type parameters to Objective-C classes, categories, forward declarations, and extensions as appropriate. Perform semantic analysis of type bounds for type parameters, both in isolation and across classes/categories/extensions to ensure consistency. Also handle (de-)serialization of Objective-C type parameter lists, along with sundry other things one must do to add a new declaration to Clang. Note that Objective-C type parameters are typedef name declarations, like typedefs and C++11 type aliases, in support of type erasure. Part of rdar://problem/6294649. llvm-svn: 241541
Diffstat (limited to 'clang/lib/Sema/SemaCodeComplete.cpp')
-rw-r--r--clang/lib/Sema/SemaCodeComplete.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/clang/lib/Sema/SemaCodeComplete.cpp b/clang/lib/Sema/SemaCodeComplete.cpp
index ff6a3ee..e4e99ab 100644
--- a/clang/lib/Sema/SemaCodeComplete.cpp
+++ b/clang/lib/Sema/SemaCodeComplete.cpp
@@ -3029,7 +3029,9 @@ CXCursorKind clang::getCursorKindForDecl(const Decl *D) {
case Decl::Import:
return CXCursor_ModuleImportDecl;
-
+
+ case Decl::ObjCTypeParam: return CXCursor_TemplateTypeParameter;
+
default:
if (const TagDecl *TD = dyn_cast<TagDecl>(D)) {
switch (TD->getTagKind()) {