10#define _USE_MATH_DEFINES
20 return *(
double*)(&
x);
59#define ok_eq_dbl_exact_(file, line, func, ullx, z, ullexp) \
61 double x = u64_to_dbl(ullx); \
62 unsigned long long ullz = dbl_to_u64(z); \
63 double exp = u64_to_dbl(ullexp); \
64 ok_(file, line)(ullz == ullexp, "Wrong value for '%s(%f)' [0x%016llx], expected: %f [0x%016llx], got: %f [0x%016llx]\n", \
65 func, x, ullx, exp, ullexp, z, ullz); \
67#define ok_eq_dbl_exact(func, ullx, z, ullexp) ok_eq_dbl_exact_(__FILE__, __LINE__, func, ullx, z, ullexp)
69#define ok_eq_flt_exact_(file, line, func, ux, z, uexp) \
71 float x = u32_to_flt(ux); \
72 unsigned int uz = flt_to_u32(z); \
73 float exp = u32_to_flt(uexp); \
74 ok_(file, line)(uz == uexp, "Wrong value for '%s(%f)' [0x%08x], expected: %f [0x%08x], got: %f [0x%08x]\n", \
75 func, x, ux, exp, uexp, z, uz); \
77#define ok_eq_flt_exact(func, ux, z, uexp) ok_eq_flt_exact_(__FILE__, __LINE__, func, ux, z, uexp)
unsigned long long UINT64
GLint GLint GLint GLint GLint x
static __inline double u64_to_dbl(UINT64 x)
struct _TESTENTRY_DBL TESTENTRY_DBL
static __inline UINT64 dbl_to_u64(double x)
struct _TESTENTRY_FLT TESTENTRY_FLT
static __inline float u32_to_flt(UINT32 x)
static __inline UINT32 flt_to_u32(float x)
unsigned long long result