Lines Matching refs:Exact
20 if acc != Exact {
28 if acc != Exact {
110 {"0", 0, "0", Exact},
111 {"-0", 0, "-0", Exact},
112 {"-Inf", 0, "-Inf", Exact},
113 {"+Inf", 0, "+Inf", Exact},
118 {"0", MaxPrec, "0", Exact},
119 {"-0", MaxPrec, "-0", Exact},
120 {"-Inf", MaxPrec, "-Inf", Exact},
121 {"+Inf", MaxPrec, "+Inf", Exact},
126 {"123", 1e6, "123", Exact},
127 {"-123", 1e6, "-123", Exact},
372 a := Exact
628 if got, acc := f.Float64(); got != want || acc != Exact {
629 t.Errorf("got %g (%s, %s); want %g (Exact)", got, f.Text('p', 0), acc, want)
763 {"-0", 0, Exact},
764 {"0", 0, Exact},
766 {"1", 1, Exact},
768 {"12345.0", 12345, Exact},
770 {"18446744073709551615", 18446744073709551615, Exact},
794 {"-9223372036854775808", -9223372036854775808, Exact},
796 {"-9223372036854775807", -9223372036854775807, Exact},
798 {"-12345.0", -12345, Exact},
801 {"-1", -1, Exact},
803 {"0", 0, Exact},
805 {"1", 1, Exact},
808 {"12345.0", 12345, Exact},
810 {"9223372036854775807", 9223372036854775807, Exact},
830 {"0", 0, Exact},
841 {"0x.0000020p-126", math.SmallestNonzeroFloat32, Exact},
842 {"0x.8p-148", math.SmallestNonzeroFloat32, Exact},
843 {"1p-149", math.SmallestNonzeroFloat32, Exact},
844 {"0x.fffffep-126", math.Float32frombits(0x7fffff), Exact}, // largest denormal
848 {"1p-126", math.Float32frombits(0x00800000), Exact}, // smallest normal
849 {"0x1.fffffep-126", math.Float32frombits(0x00ffffff), Exact},
851 {"1", 1, Exact},
853 {"12345.0", 12345, Exact},
855 {"0x1.fffffe0p127", math.MaxFloat32, Exact},
865 {"Inf", float32(math.Inf(+1)), Exact},
890 if !alike32(out2, out) || acc2 != Exact {
891 t.Errorf("idempotency test: got %g (%s); want %g (Exact)", out2, acc2, out)
904 {"0", 0, Exact},
913 {"0x0.0000000000001p-1022", math.SmallestNonzeroFloat64, Exact}, // smallest denormal
914 {"0x.8p-1073", math.SmallestNonzeroFloat64, Exact},
915 {"1p-1074", math.SmallestNonzeroFloat64, Exact},
916 {"0x.fffffffffffffp-1022", math.Float64frombits(0x000fffffffffffff), Exact}, // largest denormal
920 {"1p-1022", math.Float64frombits(0x0010000000000000), Exact}, // smallest normal
921 {"1", 1, Exact},
923 {"12345.0", 12345, Exact},
925 {"0x1.fffffffffffff0p1023", math.MaxFloat64, Exact},
933 {"Inf", math.Inf(+1), Exact},
936 {"0x.fffffffffffffp-1022", smallestNormalFloat64 - math.SmallestNonzeroFloat64, Exact},
937 {"4503599627370495p-1074", smallestNormalFloat64 - math.SmallestNonzeroFloat64, Exact},
967 if !alike64(out2, out) || acc2 != Exact {
968 t.Errorf("idempotency test: got %g (%s); want %g (Exact)", out2, acc2, out)
980 {"0", "0", Exact},
981 {"+0", "0", Exact},
982 {"-0", "0", Exact},
986 {"1", "1", Exact},
987 {"-1", "-1", Exact},
995 {"1e+10", "10000000000", Exact},
996 {"1e+100", "10000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", Exact},
1024 {"0", "0/1", Exact},
1025 {"+0", "0/1", Exact},
1026 {"-0", "0/1", Exact},
1030 {"1", "1/1", Exact},
1031 {"-1", "-1/1", Exact},
1032 {"1.25", "5/4", Exact},
1033 {"-1.25", "-5/4", Exact},
1034 {"1e10", "10000000000/1", Exact},
1035 {"1p10", "1024/1", Exact},
1036 {"-1p-10", "-1/1024", Exact},
1037 {"3.14159265", "7244019449799623199/2305843009213693952", Exact},
1162 // exact values
1210 if got != want || acc != Exact {
1211 t.Errorf("d = %d: %g + %g = %g (%s); want %g (Exact)", d, x0, y0, got, acc, want)
1217 Exact {
1218 t.Errorf("d = %d: %g - %g = %g (%s); want %g (Exact)", d, x0+y0, y0, got, acc, want)
1243 if got != want || acc != Exact {
1244 t.Errorf("d = %d: %g + %g = %g (%s); want %g (Exact)", d, x0, y0, got, acc, want)
1250 if got != want || acc != Exact {
1251 t.Errorf("d = %d: %g - %g = %g (%s); want %g (Exact)", d, x0+y0, y0, got, acc, want)
1264 // exact values
1408 if got := x.Acc(); got != Exact {
1409 t.Errorf("got acc = %s; want exact", got)
1460 if acc != Exact {
1461 t.Errorf("%g/%g got %s result; want exact result", a, b, acc)
1485 if got, acc := xx.Float64(); got != x || acc != Exact {
1553 {4, ToNearestEven, '+', "0", "0", "0", Exact}, // smoke test
1554 {4, ToNearestEven, '+', "0x.8p+0", "0x.8p+0", "0x.8p+1", Exact}, // smoke test
1556 {4, ToNearestEven, '+', "0", "0x.8p2147483647", "0x.8p+2147483647", Exact},
1570 {4, ToNearestEven, '+', "0", "0x.8p-2147483648", "0x.8p-2147483648", Exact},
1571 {4, ToNearestEven, '+', "0x.8p-2147483648", "0x.8p-2147483648", "0x.8p-2147483647", Exact},
1573 {4, ToNearestEven, '*', "1", "0x.8p2147483647", "0x.8p+2147483647", Exact},
1577 {4, ToNearestEven, '/', "0.5", "0x.8p2147483647", "0x.8p-2147483646", Exact},
1578 {4, ToNearestEven, '/', "0x.8p+0", "0x.8p2147483647", "0x.8p-2147483646", Exact},
1579 {4, ToNearestEven, '/', "0x.8p-1", "0x.8p2147483647", "0x.8p-2147483647", Exact},
1580 {4, ToNearestEven, '/', "0x.8p-2", "0x.8p2147483647", "0x.8p-2147483648", Exact},
1653 if got, acc := z.Int64(); got != test.want || acc != Exact {
1654 t.Errorf("%s, %d bits: %d %c %d = %d (%s); want %d (Exact)",
1675 if got, acc := xx.Float64(); got != x || acc != Exact {