1
0
Fork 0
mirror of https://github.com/beefytech/Beef.git synced 2025-06-08 19:48:20 +02:00

Fixed Self renaming issue

This commit is contained in:
Brian Fiete 2024-10-30 13:31:16 -04:00
parent 2c630a5ba9
commit 6c66d27ff4
5 changed files with 47 additions and 20 deletions

View file

@ -2859,7 +2859,11 @@ bool BfModule::CheckProtection(BfProtectionCheckFlags& flags, BfTypeInstance* me
}
bool allowPrivate = (curCheckType != NULL) && (memberOwner->IsInstanceOf(curCheckType->mTypeDef));
if (curCheckType != NULL)
{
allowPrivate |= IsInnerType(curCheckType->mTypeDef, memberOwner->mTypeDef);
if (memberOwner->mTypeDef->IsGlobalsContainer())
allowPrivate |= curCheckType->mTypeDef->mNamespace.StartsWith(memberOwner->mTypeDef->mNamespace);
}
if (allowPrivate)
flags = (BfProtectionCheckFlags)(flags | BfProtectionCheckFlag_AllowPrivate | BfProtectionCheckFlag_CheckedPrivate);
else