aboutsummaryrefslogtreecommitdiff
path: root/lib/Sema/SemaTemplateInstantiate.cpp
diff options
context:
space:
mode:
authorNick Lewycky <nicholas@mxc.ca>2010-07-06 19:51:49 +0000
committerNick Lewycky <nicholas@mxc.ca>2010-07-06 19:51:49 +0000
commit03d98c5d592d74ae97aa3f93f80441b64960e4b6 (patch)
tree2e4099293bc8d41a30d5613b9d7b3d34491e3da9 /lib/Sema/SemaTemplateInstantiate.cpp
parentdf921aef355ce15179f17cba839ada6347d50406 (diff)
Fix multiple emission of the this-> fixit for each instantiation by fixing the
AST during the instantiation. Fixes PR7417! git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@107690 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Sema/SemaTemplateInstantiate.cpp')
-rw-r--r--lib/Sema/SemaTemplateInstantiate.cpp8
1 files changed, 8 insertions, 0 deletions
diff --git a/lib/Sema/SemaTemplateInstantiate.cpp b/lib/Sema/SemaTemplateInstantiate.cpp
index cc9f600215..9e454bc0f2 100644
--- a/lib/Sema/SemaTemplateInstantiate.cpp
+++ b/lib/Sema/SemaTemplateInstantiate.cpp
@@ -620,6 +620,14 @@ namespace {
QualType TransformTemplateTypeParmType(TypeLocBuilder &TLB,
TemplateTypeParmTypeLoc TL,
QualType ObjectType);
+
+ Sema::OwningExprResult TransformCallExpr(CallExpr *CE) {
+ getSema().CallsUndergoingInstantiation.push_back(CE);
+ OwningExprResult Result =
+ TreeTransform<TemplateInstantiator>::TransformCallExpr(CE);
+ getSema().CallsUndergoingInstantiation.pop_back();
+ return move(Result);
+ }
};
}