summaryrefslogtreecommitdiffstats
path: root/clang/lib/Index/IndexDecl.cpp
diff options
context:
space:
mode:
authorJan Korous <jkorous@apple.com>2017-10-10 21:09:49 +0000
committerJan Korous <jkorous@apple.com>2017-10-10 21:09:49 +0000
commit330f0887d6dc98911f3913bb228d5c3592297b6d (patch)
tree1468a0a5a9a244ca491395c220b2be7e4eda43c4 /clang/lib/Index/IndexDecl.cpp
parentdecaff11aae7708efe3eefb5ad4612ad0919b7a7 (diff)
downloadbcm5719-llvm-330f0887d6dc98911f3913bb228d5c3592297b6d.tar.gz
bcm5719-llvm-330f0887d6dc98911f3913bb228d5c3592297b6d.zip
Fix indexer crash for default template template parameter value
rdar://33058798 Differential Revision: https://reviews.llvm.org/D38755 llvm-svn: 315367
Diffstat (limited to 'clang/lib/Index/IndexDecl.cpp')
-rw-r--r--clang/lib/Index/IndexDecl.cpp3
1 files changed, 1 insertions, 2 deletions
diff --git a/clang/lib/Index/IndexDecl.cpp b/clang/lib/Index/IndexDecl.cpp
index ee28ef737d9..2704e6da950 100644
--- a/clang/lib/Index/IndexDecl.cpp
+++ b/clang/lib/Index/IndexDecl.cpp
@@ -666,7 +666,6 @@ public:
}
bool VisitTemplateDecl(const TemplateDecl *D) {
- // FIXME: Template parameters.
// Index the default values for the template parameters.
const NamedDecl *Parent = D->getTemplatedDecl();
@@ -683,7 +682,7 @@ public:
} else if (const auto *TTPD = dyn_cast<TemplateTemplateParmDecl>(TP)) {
if (TTPD->hasDefaultArgument())
handleTemplateArgumentLoc(TTPD->getDefaultArgument(), Parent,
- /*DC=*/nullptr);
+ TP->getLexicalDeclContext());
}
}
}
OpenPOWER on IntegriCloud