mirror of
https://github.com/beefytech/Beef.git
synced 2025-06-08 19:48:20 +02:00
Fixed GetMethodByName for methods in conditional extensions
This commit is contained in:
parent
485316385b
commit
48571d374f
1 changed files with 7 additions and 3 deletions
|
@ -10827,10 +10827,14 @@ BfModuleMethodInstance BfModule::GetMethodByName(BfTypeInstance* typeInstance, c
|
|||
|
||||
while (methodDef != NULL)
|
||||
{
|
||||
if ((methodDef->mMethodType != BfMethodType_Mixin) &&
|
||||
if ((methodDef->mMethodType != BfMethodType_Mixin) &&
|
||||
(methodDef->mGenericParams.size() == 0) &&
|
||||
((paramCount == -1) || (paramCount == (int)methodDef->mParams.size())))
|
||||
return GetMethodInstanceAtIdx(typeInstance, methodDef->mIdx);
|
||||
((paramCount == -1) || (paramCount == (int)methodDef->mParams.size())))
|
||||
{
|
||||
auto moduleMethodInstance = GetMethodInstanceAtIdx(typeInstance, methodDef->mIdx);
|
||||
if (moduleMethodInstance)
|
||||
return moduleMethodInstance;
|
||||
}
|
||||
methodDef = methodDef->mNextWithSameName;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue