From: Chris Lattner Date: Tue, 18 Sep 2001 17:02:42 +0000 (+0000) Subject: Don't check for null on delete X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=921b5e14715f241b5050dfbe063621ded1344893;p=oota-llvm.git Don't check for null on delete git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@624 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/lib/CodeGen/InstrSelection/InstrForest.cpp b/lib/CodeGen/InstrSelection/InstrForest.cpp index efea63c3f1a..f7091a29c61 100644 --- a/lib/CodeGen/InstrSelection/InstrForest.cpp +++ b/lib/CodeGen/InstrSelection/InstrForest.cpp @@ -182,11 +182,7 @@ InstrForest::~InstrForest() { for (hash_map:: iterator I = begin(); I != end(); ++I) - { - InstructionNode* node = (*I).second; - if (node) - delete node; - } + delete (*I).second; } void diff --git a/lib/Target/SparcV9/InstrSelection/InstrForest.cpp b/lib/Target/SparcV9/InstrSelection/InstrForest.cpp index efea63c3f1a..f7091a29c61 100644 --- a/lib/Target/SparcV9/InstrSelection/InstrForest.cpp +++ b/lib/Target/SparcV9/InstrSelection/InstrForest.cpp @@ -182,11 +182,7 @@ InstrForest::~InstrForest() { for (hash_map:: iterator I = begin(); I != end(); ++I) - { - InstructionNode* node = (*I).second; - if (node) - delete node; - } + delete (*I).second; } void