diff options
Diffstat (limited to 'libgo/go/math/remainder.go')
-rw-r--r-- | libgo/go/math/remainder.go | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/libgo/go/math/remainder.go b/libgo/go/math/remainder.go index c6a4c7d..0e2903e 100644 --- a/libgo/go/math/remainder.go +++ b/libgo/go/math/remainder.go @@ -59,6 +59,10 @@ func remainder(x, y float64) float64 { y = -y } if x == y { + if sign { + zero := 0.0 + return -zero + } return 0 } if y <= HalfMax { |