aboutsummaryrefslogtreecommitdiff
path: root/lib/Sema/TreeTransform.h
diff options
context:
space:
mode:
authorRichard Smith <richard-llvm@metafoo.co.uk>2012-05-15 06:15:11 +0000
committerRichard Smith <richard-llvm@metafoo.co.uk>2012-05-15 06:15:11 +0000
commit6314db9d5918939ad8ec88cd9c3f42a33a67c2b6 (patch)
tree842280784b995456412cd8834cde1357b86bcf02 /lib/Sema/TreeTransform.h
parent455e3e18b8ec4a7ba3a412b9b6be99b19b7c6970 (diff)
PR12798: Don't drop part of the nested name specifier when instantiating a
pseudo-destructor expression. This can affect whether virtual dispatch for the destructor call is bypassed. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@156806 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Sema/TreeTransform.h')
-rw-r--r--lib/Sema/TreeTransform.h6
1 files changed, 5 insertions, 1 deletions
diff --git a/lib/Sema/TreeTransform.h b/lib/Sema/TreeTransform.h
index 7387eac667..01b82aa3d7 100644
--- a/lib/Sema/TreeTransform.h
+++ b/lib/Sema/TreeTransform.h
@@ -9268,7 +9268,11 @@ TreeTransform<Derived>::RebuildCXXPseudoDestructorExpr(Expr *Base,
DeclarationNameInfo NameInfo(Name, Destroyed.getLocation());
NameInfo.setNamedTypeInfo(DestroyedType);
- // FIXME: the ScopeType should be tacked onto SS.
+ // The scope type is now known to be a valid nested name specifier
+ // component. Tack it on to the end of the nested name specifier.
+ if (ScopeType)
+ SS.Extend(SemaRef.Context, SourceLocation(),
+ ScopeType->getTypeLoc(), CCLoc);
SourceLocation TemplateKWLoc; // FIXME: retrieve it from caller.
return getSema().BuildMemberReferenceExpr(Base, BaseType,