Revert "reflect: when Converting between float32s, don't lose signal NaNs"

This reverts commit 7485050c0f.

Reason for revert: Breaking some builders (387, mips, mips64)

Change-Id: I33e5125b7a9a96b55bc5e71880fca4ee30d226a7
Reviewed-on: https://go-review.googlesource.com/c/go/+/220695
Run-TryBot: Keith Randall <khr@golang.org>
Reviewed-by: Josh Bleecher Snyder <josharian@gmail.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
This commit is contained in:
Keith Randall 2020-02-25 05:57:22 +00:00
parent 0d4fa27fd7
commit 0d6b317ee6
2 changed files with 0 additions and 25 deletions

View file

@ -4163,17 +4163,6 @@ func TestConvert(t *testing.T) {
}
}
func TestConvertNaNs(t *testing.T) {
const snan uint32 = 0x7f800001
type myFloat32 float32
x := V(myFloat32(math.Float32frombits(snan)))
y := x.Convert(TypeOf(float32(0)))
z := y.Interface().(float32)
if got := math.Float32bits(z); got != snan {
t.Errorf("signaling nan conversion got %x, want %x", got, snan)
}
}
type ComparableStruct struct {
X int
}