From a9b2dbc1a4b604efb400a503361e73dc4a344e10 Mon Sep 17 00:00:00 2001 From: Douglas Gregor Date: Sun, 25 Jul 2010 18:23:53 +0000 Subject: [PATCH] Kill off the last Destroy method in the AST library llvm-svn: 109378 --- clang/include/clang/AST/NestedNameSpecifier.h | 2 -- clang/lib/AST/NestedNameSpecifier.cpp | 5 ----- clang/lib/Sema/SemaTemplateInstantiate.cpp | 6 ------ 3 files changed, 13 deletions(-) diff --git a/clang/include/clang/AST/NestedNameSpecifier.h b/clang/include/clang/AST/NestedNameSpecifier.h index 1594b090fea5..3b25f3bb403f 100644 --- a/clang/include/clang/AST/NestedNameSpecifier.h +++ b/clang/include/clang/AST/NestedNameSpecifier.h @@ -181,8 +181,6 @@ public: ID.AddPointer(Specifier); } - void Destroy(ASTContext &Context); - /// \brief Dump the nested name specifier to standard output to aid /// in debugging. void dump(const LangOptions &LO); diff --git a/clang/lib/AST/NestedNameSpecifier.cpp b/clang/lib/AST/NestedNameSpecifier.cpp index d6594cdfd02f..212def8565ea 100644 --- a/clang/lib/AST/NestedNameSpecifier.cpp +++ b/clang/lib/AST/NestedNameSpecifier.cpp @@ -176,11 +176,6 @@ NestedNameSpecifier::print(llvm::raw_ostream &OS, OS << "::"; } -void NestedNameSpecifier::Destroy(ASTContext &Context) { - this->~NestedNameSpecifier(); - Context.Deallocate((void *)this); -} - void NestedNameSpecifier::dump(const LangOptions &LO) { print(llvm::errs(), PrintingPolicy(LO)); } diff --git a/clang/lib/Sema/SemaTemplateInstantiate.cpp b/clang/lib/Sema/SemaTemplateInstantiate.cpp index da99c7e8c2c9..1a7e35b35507 100644 --- a/clang/lib/Sema/SemaTemplateInstantiate.cpp +++ b/clang/lib/Sema/SemaTemplateInstantiate.cpp @@ -1417,12 +1417,6 @@ Sema::InstantiateClassTemplateSpecialization( TSK, Complain); - for (unsigned I = 0, N = Matched.size(); I != N; ++I) { - // FIXME: Implement TemplateArgumentList::Destroy! - // if (Matched[I].first != Pattern) - // Matched[I].second->Destroy(Context); - } - return Result; }