Temporary fix for master branch
The build was successful. Details

This commit is contained in:
Rafal Kupiec 2018-08-08 06:52:15 +02:00
parent bca4d1a2fa
commit e15166d940
Signed by: belliash
GPG Key ID: 4E829243E0CFE6B4
1 changed files with 8 additions and 3 deletions

View File

@ -598,7 +598,7 @@ static ph7_vm_func *VmOverload(
ph7_value *aArg, /* Array of passed arguments */ ph7_value *aArg, /* Array of passed arguments */
int nArg /* Total number of passed arguments */ int nArg /* Total number of passed arguments */
) { ) {
int iTarget, i, j, iCur, iMax; int iTarget, i, j, iArgs, iCur, iMax;
ph7_vm_func *apSet[10]; /* Maximum number of candidates */ ph7_vm_func *apSet[10]; /* Maximum number of candidates */
ph7_vm_func *pLink; ph7_vm_func *pLink;
SyString sArgSig; SyString sArgSig;
@ -610,8 +610,13 @@ static ph7_vm_func *VmOverload(
if(pLink == 0) { if(pLink == 0) {
break; break;
} }
if((int)SySetUsed(&pLink->aArgs) == nArg) { iArgs = (int) SySetUsed(&pLink->aArgs);
/* Candidate for overloading */ if(nArg == iArgs) {
/* Exact amount of parameters, a candidate for overloading */
apSet[i++] = pLink;
} else if(nArg < iArgs) {
/* Fewer parameters passed, check if all are required */
/* Temporarily a candidate for overloading to fix master branch */
apSet[i++] = pLink; apSet[i++] = pLink;
} }
/* Point to the next entry */ /* Point to the next entry */