#include "mathlink.h"
int AppYieldFunction1 (MLINK mlp, MLYieldParameters yp)
{
/* ... */
return 0;
}
int AppYieldFunction2 (MLINK mlp, MLYieldParameters yp)
{
/* ... */
return 0;
}
/* check which yield function is installed in a link */
int f(MLINK lp)
{
MLYieldFunctionObject yf;
yf = MLGetYieldFunction(lp);
if(yf
(MLYieldFunctionObject)AppYieldFunction1) return 1;
else if(yf
(MLYieldFunctionObject)AppYieldFunction2) return 2;
else if(yf
(MLYieldFunctionObject)0) return 0;
return -1;
}