aboutsummaryrefslogtreecommitdiff
path: root/lib/Sema/SemaCodeComplete.cpp
diff options
context:
space:
mode:
authorDouglas Gregor <dgregor@apple.com>2009-12-11 16:18:54 +0000
committerDouglas Gregor <dgregor@apple.com>2009-12-11 16:18:54 +0000
commite29ffaae9b2f474b1cf559704c66de8498177559 (patch)
tree62debd875a65cb8a79c42478cefc2a58d704acfd /lib/Sema/SemaCodeComplete.cpp
parent8d04258483be6583f0865464234d014807a3e1cc (diff)
Class template (partial) specializations should not show up in code completion results
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91125 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Sema/SemaCodeComplete.cpp')
-rw-r--r--lib/Sema/SemaCodeComplete.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/lib/Sema/SemaCodeComplete.cpp b/lib/Sema/SemaCodeComplete.cpp
index 73e0ab0fad..63c8bdcc6c 100644
--- a/lib/Sema/SemaCodeComplete.cpp
+++ b/lib/Sema/SemaCodeComplete.cpp
@@ -363,6 +363,11 @@ void ResultBuilder::MaybeAddResult(Result R, DeclContext *CurContext) {
if (isa<FriendDecl>(CanonDecl) ||
(IDNS & (Decl::IDNS_OrdinaryFriend | Decl::IDNS_TagFriend)))
return;
+
+ // Class template (partial) specializations are never added as results
+ if (isa<ClassTemplateSpecializationDecl>(CanonDecl) ||
+ isa<ClassTemplatePartialSpecializationDecl>(CanonDecl))
+ return;
if (const IdentifierInfo *Id = R.Declaration->getIdentifier()) {
// __va_list_tag is a freak of nature. Find it and skip it.