+
+ static double VALUE = 0.19975845134874831D;
+
+ public static int test_0_float_conversion_reduces_double_precision () {
+ double d = (float)VALUE;
+ if (d != 0.19975845515727997d)
+ return 1;
+
+ return 0;
+ }
+
+
+ public static int test_0_long_to_double_conversion ()
+ {
+ long l = 9223372036854775807L;
+ long conv = (long)((double)l);
+ if (conv != -9223372036854775808L)
+ return 1;
+
+ return 0;
+ }
+
+ public static int INT_VAL = 0x13456799;
+
+ public static int test_0_int4_to_float_convertion ()
+ {
+ double d = (double)(float)INT_VAL;
+
+ if (d != 323315616)
+ return 1;
+ return 0;
+ }
+
+ public static int test_0_int8_to_float_convertion ()
+ {
+ double d = (double)(float)(long)INT_VAL;
+
+ if (d != 323315616)
+ return 1;
+ return 0;
+ }