mirror of
https://github.com/beefytech/Beef.git
synced 2025-06-10 12:32:20 +02:00
Fixed mixin node reference with target specifiers
This commit is contained in:
parent
aacabd2e13
commit
b784101e93
1 changed files with 15 additions and 0 deletions
|
@ -15732,6 +15732,21 @@ void BfExprEvaluator::InjectMixin(BfAstNode* targetSrc, BfTypedValue target, boo
|
|||
if (scopedInvocationTarget != NULL)
|
||||
targetNameNode = scopedInvocationTarget->mTarget;
|
||||
|
||||
while (true)
|
||||
{
|
||||
if (auto qualifiedNameNode = BfNodeDynCast<BfQualifiedNameNode>(targetNameNode))
|
||||
{
|
||||
targetNameNode = qualifiedNameNode->mRight;
|
||||
continue;
|
||||
}
|
||||
if (auto memberRefExpr = BfNodeDynCast<BfMemberReferenceExpression>(targetNameNode))
|
||||
{
|
||||
targetNameNode = memberRefExpr->mMemberName;
|
||||
continue;
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
||||
BfTypeInstance* mixinClass = NULL;
|
||||
if (target.mType != NULL)
|
||||
mixinClass = target.mType->ToTypeInstance();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue