aboutsummaryrefslogtreecommitdiff
path: root/lib/Sema/SemaTemplate.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'lib/Sema/SemaTemplate.cpp')
-rw-r--r--lib/Sema/SemaTemplate.cpp10
1 files changed, 2 insertions, 8 deletions
diff --git a/lib/Sema/SemaTemplate.cpp b/lib/Sema/SemaTemplate.cpp
index 79d7e2c9ae..47388ace34 100644
--- a/lib/Sema/SemaTemplate.cpp
+++ b/lib/Sema/SemaTemplate.cpp
@@ -2340,11 +2340,8 @@ Sema::ActOnExplicitInstantiation(Scope *S, SourceLocation TemplateLoc,
// instantiation.
if (SpecializationRequiresInstantiation)
InstantiateClassTemplateSpecialization(Specialization, true);
- else {
- // Instantiate the members of this class template specialization.
- InstantiatingTemplate Inst(*this, TemplateLoc, Specialization);
+ else // Instantiate the members of this class template specialization.
InstantiateClassTemplateSpecializationMembers(TemplateLoc, Specialization);
- }
return DeclPtrTy::make(Specialization);
}
@@ -2405,12 +2402,9 @@ Sema::ActOnExplicitInstantiation(Scope *S, SourceLocation TemplateLoc,
getTemplateInstantiationArgs(Record),
/*ExplicitInstantiation=*/true))
return true;
- } else {
- // Instantiate all of the members of class.
- InstantiatingTemplate Inst(*this, TemplateLoc, Record);
+ } else // Instantiate all of the members of class.
InstantiateClassMembers(TemplateLoc, Record,
getTemplateInstantiationArgs(Record));
- }
// FIXME: We don't have any representation for explicit instantiations of
// member classes. Such a representation is not needed for compilation, but it