forked from OSchip/llvm-project
Don't delete things before their last use (avoids bad reads).
llvm-svn: 35214
This commit is contained in:
parent
25878b45f5
commit
0ad5cebb09
|
@ -1302,7 +1302,6 @@ Types
|
|||
Attrs.push_back($5);
|
||||
for (TypeWithAttrsList::iterator I=$3->begin(), E=$3->end(); I != E; ++I) {
|
||||
const Type *Ty = I->Ty->get();
|
||||
delete I->Ty; I->Ty = 0;
|
||||
Params.push_back(Ty);
|
||||
if (Ty != Type::VoidTy)
|
||||
Attrs.push_back(I->Attrs);
|
||||
|
@ -1322,7 +1321,6 @@ Types
|
|||
Attrs.push_back($5);
|
||||
for (TypeWithAttrsList::iterator I=$3->begin(), E=$3->end(); I != E; ++I) {
|
||||
const Type* Ty = I->Ty->get();
|
||||
delete I->Ty; I->Ty = 0;
|
||||
Params.push_back(Ty);
|
||||
if (Ty != Type::VoidTy)
|
||||
Attrs.push_back(I->Attrs);
|
||||
|
|
Loading…
Reference in New Issue