19 M_PI, -M_PI, 123456.789, -123456.789,
20#if defined(NAN) && defined(INFINITY)
21 INFINITY, -INFINITY, NAN, INFINITY - INFINITY,
23 1e38, -1e38, 1e39, -1e39,
24 1e-38, -1e-38, 1e-39, -1e-39,
25 3.14159e-37,-3.14159e-37, 3.14159e-43, -3.14159e-43,
26 1e-60, -1e-60, 1e-45, -1e-45,
27 0.99999999999999, -0.99999999999999, 127.999999999999, -127.999999999999
41 float expected_float = (float)orig_double;
42 double expected_double = (double)expected_float;
44 printf(
"\n---- Testcase: %f ----\n", expected_float);
49 DoubleMsg msg = { 0.0 };
50 msg.value = orig_double;
52 msglen = stream.bytes_written;
67 msglen = ostream.bytes_written;
74 DoubleMsg msg = { 0.0 };
77 if (isnan(expected_double))
80 TEST(isnan(msg.value));
84 TEST(
memcmp(&msg.value, &expected_double,
sizeof(
double)) == 0);