diff options
author | Douglas Gregor <dgregor@apple.com> | 2010-11-05 23:22:45 +0000 |
---|---|---|
committer | Douglas Gregor <dgregor@apple.com> | 2010-11-05 23:22:45 +0000 |
commit | a43064c7b721a51ab2c0d0ccdc4f84064aa7cecc (patch) | |
tree | 9a22bd48663a918d76db84e5a816546372da1429 /lib/Sema/SemaTemplateInstantiateDecl.cpp | |
parent | 464b2f0ab31f6de8761f76f6754809f9746f4584 (diff) |
When searching for an instantiated declaration requires instantiation
of its parent context, be sure to update the parent-context pointer
after instantiation. Fixes two anonymous-union instantiation issues in
<rdar://problem/8635664>.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@118313 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Sema/SemaTemplateInstantiateDecl.cpp')
-rw-r--r-- | lib/Sema/SemaTemplateInstantiateDecl.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/lib/Sema/SemaTemplateInstantiateDecl.cpp b/lib/Sema/SemaTemplateInstantiateDecl.cpp index 6e352e71ef..a594e678d6 100644 --- a/lib/Sema/SemaTemplateInstantiateDecl.cpp +++ b/lib/Sema/SemaTemplateInstantiateDecl.cpp @@ -2753,6 +2753,8 @@ NamedDecl *Sema::FindInstantiatedDecl(SourceLocation Loc, NamedDecl *D, if (!Tag->isBeingDefined() && RequireCompleteType(Loc, T, diag::err_incomplete_type)) return 0; + + ParentDC = Tag->getDecl(); } } |