#include "common.h"
#ifdef LACKS_ISNAN
#include "matfile.h"

#if PROTOTYPE_ALLOWED
int isnan(double d)
#else
int isnan(d)
double d;
#endif
{
   long l[2];

   strncpy((char *) l, (char *) &d, sizeof(double));
   return(l[0] == NaN_d_0 && l[1] == NaN_d_1);
}

#else
/* dummy function so ranlib doesn't complain about missing
symbol table.
*/

#if PROTOTYPE_ALLOWED
int dummyxxxxxx(double d)
#else
int dummyxxxxxx(d)
double d;
#endif
{
return(0);
/* absolutely nothing! */
}

#endif
