parent
4a68f9b606
commit
950ad65841
|
@ -2323,7 +2323,7 @@ bool BitcodeReader::ParseFunctionBody(Function *F) {
|
|||
if (A->getParent() == 0) {
|
||||
// We found at least one unresolved value. Nuke them all to avoid leaks.
|
||||
for (unsigned i = ModuleValueListSize, e = ValueList.size(); i != e; ++i){
|
||||
if ((A = dyn_cast<Argument>(ValueList.back())) && A->getParent() == 0) {
|
||||
if ((A = dyn_cast<Argument>(ValueList[i])) && A->getParent() == 0) {
|
||||
A->replaceAllUsesWith(UndefValue::get(A->getType()));
|
||||
delete A;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue