1
0
Fork 0
mirror of https://github.com/beefytech/Beef.git synced 2025-06-08 11:38:21 +02:00

TypeDef cleanup fixes

This commit is contained in:
Brian Fiete 2020-12-23 09:45:19 -08:00
parent 3611846b7f
commit 31c89ab8e1

View file

@ -2347,6 +2347,7 @@ BfClosureType::BfClosureType(BfTypeInstance* srcDelegate, Val128 closureHash) :
BfClosureType::~BfClosureType() BfClosureType::~BfClosureType()
{ {
mMethodInstanceGroups.Clear();
if (mCreatedTypeDef) if (mCreatedTypeDef)
delete mTypeDef; delete mTypeDef;
for (auto directAllocNode : mDirectAllocNodes) for (auto directAllocNode : mDirectAllocNodes)
@ -2425,6 +2426,7 @@ void BfClosureType::Finish()
BfDelegateType::~BfDelegateType() BfDelegateType::~BfDelegateType()
{ {
mMethodInstanceGroups.Clear();
delete mTypeDef; delete mTypeDef;
} }
@ -2441,6 +2443,7 @@ BfTupleType::BfTupleType()
BfTupleType::~BfTupleType() BfTupleType::~BfTupleType()
{ {
mMethodInstanceGroups.Clear();
if (mCreatedTypeDef) if (mCreatedTypeDef)
delete mTypeDef; delete mTypeDef;
delete mSource; delete mSource;