Page 1 of 1

passing functions as parameters to functions

Posted: Sat Mar 29, 2008 9:36 am
by phao
for exemple:

Code: Select all

function f(fref g(value), x)
    return g(x);
endfunction
I use 'fref' in the exemple to show that 'g' is the function reference passed to the function 'f'.

I think using this syntax:

Code: Select all

function f(fref g, x)
    return g(x);
endfunction
It would be better (IMO).