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

Make failed indexer match failover to first indexer decl

This commit is contained in:
Brian Fiete 2022-05-15 18:14:45 -07:00
parent b4b0edf453
commit 2432ab4921

View file

@ -20960,8 +20960,7 @@ void BfExprEvaluator::Visit(BfIndexerExpression* indexerExpr)
methodMatcher.mTarget = target;
methodMatcher.CheckMethod(startCheckTypeInst, curCheckType, checkMethod, false);
if ((methodMatcher.mBestMethodDef == checkMethod) ||
((foundProp == NULL) && (methodMatcher.mBackupMethodDef == checkMethod)))
if ((methodMatcher.mBestMethodDef == checkMethod) || (methodMatcher.mBackupMethodDef == checkMethod))
{
foundPropTypeInst = curCheckType;
foundProp = prop;