From: Chris Lattner Date: Wed, 5 Mar 2008 00:53:34 +0000 (+0000) Subject: move this into the right file. X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=544f043d7667d581792f3ac232d24343481d61d7;p=clang move this into the right file. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@47925 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/Basic/TargetInfo.cpp b/Basic/TargetInfo.cpp index 069e144a74..15472a473c 100644 --- a/Basic/TargetInfo.cpp +++ b/Basic/TargetInfo.cpp @@ -53,6 +53,12 @@ void TargetInfo::getLongDoubleInfo(uint64_t &Size, unsigned &Align, //===----------------------------------------------------------------------===// +TargetInfo::~TargetInfo() { + delete PrimaryTarget; + for (unsigned i = 0; i < SecondaryTargets.size(); ++i) + delete SecondaryTargets[i]; +} + const char* TargetInfo::getTargetTriple() const { return PrimaryTarget->getTargetTriple(); } diff --git a/Basic/Targets.cpp b/Basic/Targets.cpp index d87e386fa9..7d64942b4f 100644 --- a/Basic/Targets.cpp +++ b/Basic/Targets.cpp @@ -827,9 +827,3 @@ TargetInfo* TargetInfo::CreateTargetInfo(const std::string* TriplesStart, return TI; } -TargetInfo::~TargetInfo() { - delete PrimaryTarget; - for (unsigned i = 0; i < SecondaryTargets.size(); ++i) - delete SecondaryTargets[i]; -} -