Comment 2 for bug 1159053

Revision history for this message
Gábor Csárdi (gabor.csardi) wrote :

platform.h has:

#ifdef _MSC_VER
#define snprintf sprintf_s
#define isnan(x) _isnan(x)
#ifndef INFINITY
# define INFINITY (DBL_MAX+DBL_MAX)
#endif

#ifndef NAN
# define NAN (INFINITY-INFINITY)
#endif

#endif

So this is for MSVC only, I guess. So you would need something like this:

#include <math.h>

#ifndef INFINITY
# define INFINITY (1.0/0.0)
#endif

#ifndef NAN
# define NAN (INFINITY-INFINITY)
#endif