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

Allow function binding to generic interface constraint method

This commit is contained in:
Brian Fiete 2020-12-26 08:19:30 -08:00
parent 5808bd555c
commit 6029315ff6
2 changed files with 9 additions and 2 deletions

View file

@ -3813,7 +3813,7 @@ bool BfResolvedTypeSet::Equals(BfType* lhs, BfTypeReference* rhs, LookupContext*
bool isMutating = true;
int paramRefOfs = 0;
if (!rhsDelegateType->mParams.IsEmpty())
if ((!rhsDelegateType->mParams.IsEmpty()) && (lhs->IsFunction()))
{
auto param0 = rhsDelegateType->mParams[0];
if ((param0->mNameNode != NULL) && (param0->mNameNode->Equals("this")))