summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRichard Smith <richard-llvm@metafoo.co.uk>2019-02-15 21:48:09 +0000
committerRichard Smith <richard-llvm@metafoo.co.uk>2019-02-15 21:48:09 +0000
commit35b007e9a9f272d8570ec1009e1e7cb0aa064600 (patch)
tree2d3bb60b225aa6c93568a8baf5f2a2a3b8001e3c
parenta2d9fdf5b65ab1b17409d7a7eae74802cb569c5d (diff)
downloadbcm5719-llvm-35b007e9a9f272d8570ec1009e1e7cb0aa064600.tar.gz
bcm5719-llvm-35b007e9a9f272d8570ec1009e1e7cb0aa064600.zip
Fix AST generated for a class template to connect the class inside a
class template back to the template. Previously, when the ASTImporter imported the class, it didn't know that it was the pattern of a class template, so made the class a name lookup result for the name of the template, resulting in ambiguity errors when naming the template. Due to a clang bug (fixed in r354091, reverted and soon to be re-committed), ambiguity errors between a template and a non-template were previously not diagnosed. Once r354091 is re-committed, this will be covered by existing lldb tests. llvm-svn: 354173
-rw-r--r--lldb/source/Symbol/ClangASTContext.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/lldb/source/Symbol/ClangASTContext.cpp b/lldb/source/Symbol/ClangASTContext.cpp
index 190dd77f4e4..aafbe2ec1c3 100644
--- a/lldb/source/Symbol/ClangASTContext.cpp
+++ b/lldb/source/Symbol/ClangASTContext.cpp
@@ -1654,6 +1654,7 @@ ClassTemplateDecl *ClangASTContext::CreateClassTemplateDecl(
decl_ctx, // What decl context do we use here? TU? The actual decl
// context?
SourceLocation(), decl_name, template_param_list, template_cxx_decl);
+ template_cxx_decl->setDescribedClassTemplate(class_template_decl);
if (class_template_decl) {
if (access_type != eAccessNone)
OpenPOWER on IntegriCloud