]> granicus.if.org Git - clang/commitdiff
A leak is better than a double-free while I figure out how to address
authorDouglas Gregor <dgregor@apple.com>
Sat, 8 May 2010 18:32:25 +0000 (18:32 +0000)
committerDouglas Gregor <dgregor@apple.com>
Sat, 8 May 2010 18:32:25 +0000 (18:32 +0000)
this issue.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@103343 91177308-0d34-0410-b5e6-96231b3b80d8

lib/Sema/SemaOverload.cpp

index 6f7063b98f361cf8f3a9711e19e62d5744052f1d..136183a0accb94a397ae7da426e6ef5dc97a8a41 100644 (file)
@@ -425,11 +425,6 @@ OverloadCandidate::DeductionFailureInfo::getSecondArg() {
 }
 
 void OverloadCandidateSet::clear() {
-  for (iterator C = begin(), CEnd = end(); C != CEnd; ++C) {
-    if (C->FailureKind == ovl_fail_bad_deduction)
-      C->DeductionFailure.Destroy();
-  }
-       
   inherited::clear();
   Functions.clear();
 }