diff options
author | Ondřej Surý <ondrej@sury.org> | 2011-02-18 09:50:58 +0100 |
---|---|---|
committer | Ondřej Surý <ondrej@sury.org> | 2011-02-18 09:53:27 +0100 |
commit | 91664defe0a75da15661a37a7f585b0c8523bf4e (patch) | |
tree | 8d7133037ce477c00ba0408d3f0892e0a8b5744d /src/pkg/strconv/ftoa.go | |
parent | ac2d3c9eb73a2d23848c55c3171d8ff6dd0feed9 (diff) | |
download | golang-91664defe0a75da15661a37a7f585b0c8523bf4e.tar.gz |
Imported Upstream version 2011.02.15
Diffstat (limited to 'src/pkg/strconv/ftoa.go')
-rw-r--r-- | src/pkg/strconv/ftoa.go | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/pkg/strconv/ftoa.go b/src/pkg/strconv/ftoa.go index 4ec3cdbb9..b6049c545 100644 --- a/src/pkg/strconv/ftoa.go +++ b/src/pkg/strconv/ftoa.go @@ -64,7 +64,7 @@ func FtoaN(f float64, fmt byte, prec int, n int) string { } func genericFtoa(bits uint64, fmt byte, prec int, flt *floatInfo) string { - neg := bits>>flt.expbits>>flt.mantbits != 0 + neg := bits>>(flt.expbits+flt.mantbits) != 0 exp := int(bits>>flt.mantbits) & (1<<flt.expbits - 1) mant := bits & (uint64(1)<<flt.mantbits - 1) |