2 #error "Use this header only with Microsoft Visual C++ compilers!"
5 #ifndef _MSC_CONFIG_H_ // [
12 #define inline __inline
26 static inline long lrint(
double x) {
return (
long)(x > 0.0 ? x + 0.5 : x - 0.5); }
27 static inline long lrintf(
float x) {
return (
long)(x > 0.0f ? x + 0.5f : x - 0.5f); }
28 static inline long long llrint(
double x)
30 return (
long long)(x > 0.0 ? x + 0.5 : x - 0.5);
34 return (
long long)(x > 0.0f ? x + 0.5f : x - 0.5f);
36 static inline double rint(
double x) {
return (x > 0.0) ? floor(x + 0.5) : ceil(x - 0.5); }
37 static inline float rintf(
float x)
39 return (x > 0.0f) ? floorf(x + 0.5f) : ceilf(x - 0.5f);
48 #define INFINITY HUGE_VAL
55 static inline long int random(
void) {
return rand(); }
56 static inline void srandom(
unsigned int seed) { srand(seed); }
58 #endif // _MSC_CONFIG_H_ ]