1
0
Fork 0
mirror of https://github.com/beefytech/Beef.git synced 2025-06-09 20:12:21 +02:00

Fixed issue with new stricter IsValueless check

This commit is contained in:
Brian Fiete 2020-04-24 16:56:29 -07:00
parent 35abc1d591
commit 868293f2f2

View file

@ -2984,6 +2984,9 @@ bool BfModule::DoPopulateType(BfType* resolvedTypeRef, BfPopulateType populateTy
std::function<void(BfType*)> splatIterate;
splatIterate = [&](BfType* checkType)
{
if (checkType->IsValueType())
PopulateType(checkType, BfPopulateType_Data);
if (checkType->IsMethodRef())
{
// For simplicitly, any methodRef inside a struct makes the struct non-splattable. This reduces cases of needing to
@ -2992,7 +2995,6 @@ bool BfModule::DoPopulateType(BfType* resolvedTypeRef, BfPopulateType populateTy
}
else if (checkType->IsStruct())
{
PopulateType(checkType, BfPopulateType_Data);
auto checkTypeInstance = checkType->ToTypeInstance();
if (checkTypeInstance->mBaseType != NULL)
splatIterate(checkTypeInstance->mBaseType);