<< Boolean sparse writing (Scilab gateway) Low level functions Check variable dimensions (Scilab gateway) >>

Scilab Help >> API Scilab > legacy > Low level functions > CallOverloadFunction

CallOverloadFunction

a C gateway function uses to call overload function or macro

Syntax

CallOverloadFunction(_iVar)

Arguments

iVar

Specifies which input argument will be used to create the name of overload function/macro

Description

a C gateway function uses to call overload function or macro

Examples

This example returns the size:

Gateway Source

int callOverload(char *fname,void* pvApiCtx)
{
    CheckRhs(1, 1);
    CheckLhs(0, 1);

    CallOverloadFunction(1);
    return 0;
}

Scilab test script

function x=%c_getSize(a)
    x = length(a);
endfunction

function x=%s_getSize(a)
    x = size(a);
endfunction

a = [1,2,3,4];
a_ref = [2,2];
assert_checkequal(getSize(a) == a_ref);

b = ["May","the","puffin";"be","with","you"];
b_ref = [3,3,6;2,4,3];
assert_checkequal(getSize(b) == b_ref);

Report an issue
<< Boolean sparse writing (Scilab gateway) Low level functions Check variable dimensions (Scilab gateway) >>