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

Improvements to handling of pointers to reference types

This commit is contained in:
Brian Fiete 2022-01-04 07:17:32 -05:00
parent 0030236705
commit 8a4bf7ac8c
2 changed files with 32 additions and 17 deletions

View file

@ -1878,7 +1878,11 @@ bool BfAutoComplete::CheckMemberReference(BfAstNode* target, BfAstNode* dotToken
}
if (checkType->IsPointer())
checkType = checkType->GetUnderlyingType();
{
auto underlyingType = checkType->GetUnderlyingType();
if ((underlyingType != NULL) && (underlyingType->IsValueType()))
checkType = underlyingType;
}
auto typeInst = checkType->ToTypeInstance();
if ((typeInst == NULL) &&
((checkType->IsPrimitiveType()) || (checkType->IsSizedArray())))