summaryrefslogtreecommitdiff
path: root/tools
diff options
context:
space:
mode:
authorArgyrios Kyrtzidis <akyrtzi@gmail.com>2012-01-23 16:58:41 +0000
committerArgyrios Kyrtzidis <akyrtzi@gmail.com>2012-01-23 16:58:41 +0000
commit145f7b2093a0050621141acd089e09edf6118a09 (patch)
tree7e5c1c9d63aeebe0231ae6873ea0a1095f2f6c5e /tools
parent55fa1d9b7ecb042d810b2f0f68d70492dc39e46f (diff)
downloadclang-145f7b2093a0050621141acd089e09edf6118a09.tar.gz
clang-145f7b2093a0050621141acd089e09edf6118a09.tar.bz2
clang-145f7b2093a0050621141acd089e09edf6118a09.tar.xz
[libclang] Index C++ template specializations, rdar://10732708
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@148707 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'tools')
-rw-r--r--tools/libclang/IndexTypeSourceInfo.cpp8
1 files changed, 8 insertions, 0 deletions
diff --git a/tools/libclang/IndexTypeSourceInfo.cpp b/tools/libclang/IndexTypeSourceInfo.cpp
index 1b2069d30d..e326404842 100644
--- a/tools/libclang/IndexTypeSourceInfo.cpp
+++ b/tools/libclang/IndexTypeSourceInfo.cpp
@@ -70,6 +70,14 @@ public:
}
return true;
}
+
+ bool VisitTemplateSpecializationTypeLoc(TemplateSpecializationTypeLoc TL) {
+ if (const TemplateSpecializationType *T = TL.getTypePtr())
+ if (const TemplateDecl *D = T->getTemplateName().getAsTemplateDecl())
+ IndexCtx.handleReference(D, TL.getTemplateNameLoc(),
+ Parent, ParentDC);
+ return true;
+ }
};
} // anonymous namespace