Higher-order functions: Difference between revisions
→Complex example: Removed syntax highlighting
(→Simple example: Removed syntax highlighting) |
(→Complex example: Removed syntax highlighting) |
||
Line 41:
Definition of a function whose return value is a pointer to int and whose only parameter is a pointer to a function, whose (in turn) return value is a pointer to double and whose only parameter is a pointer to long.
int* myFuncComplex( double* (*funcParameter)(long* parameter) )
{
Line 54 ⟶ 53:
/* ... */
}
Call:
double* funcToBePassed(long* parameter);
Line 65 ⟶ 62:
outInt = myFuncComplex(&funcToBePassed);
===Pointer===
|