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

Allow ? match to 'out' during CheckMethod

This commit is contained in:
Brian Fiete 2022-03-19 08:20:51 -07:00
parent fad6b49908
commit 7cb92e4007

View file

@ -2170,7 +2170,15 @@ bool BfMethodMatcher::CheckMethod(BfTypeInstance* targetTypeInstance, BfTypeInst
}
}
goto NoMatch;
bool matches = false;
if (wantType->IsOut())
{
if (auto memberRefExpr = BfNodeDynCast<BfUninitializedExpression>(mArguments[argIdx].mExpression))
matches = true;
}
if (!matches)
goto NoMatch;
}
else
{