clean ArgTypeListI production: free the PATypeHolder

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@57113 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Nuno Lopes 2008-10-05 16:49:03 +00:00
parent ff4ca2e088
commit d0ad67788d

View File

@ -1422,9 +1422,15 @@ Types
CHECK_FOR_ERROR
FunctionType *FT = FunctionType::get(RetTy, Params, isVarArg);
delete $3; // Delete the argument list
delete $1; // Delete the return type handle
$$ = new PATypeHolder(HandleUpRefs(FT));
// Delete the argument list
for (I = $3->begin() ; I != E; ++I ) {
delete I->Ty;
}
delete $3;
CHECK_FOR_ERROR
}
| VOID '(' ArgTypeListI ')' OptFuncAttrs {
@ -1447,8 +1453,14 @@ Types
CHECK_FOR_ERROR
FunctionType *FT = FunctionType::get($1, Params, isVarArg);
delete $3; // Delete the argument list
$$ = new PATypeHolder(HandleUpRefs(FT));
// Delete the argument list
for (I = $3->begin() ; I != E; ++I ) {
delete I->Ty;
}
delete $3;
CHECK_FOR_ERROR
}