mirror of
https://github.com/shopspring/decimal.git
synced 2024-11-22 20:40:48 +01:00
fix: NewFromFloat(1.1001).RoundHalfDown(2).String() // output: 1.10
This commit is contained in:
parent
54e62db847
commit
1b31f22216
1 changed files with 1 additions and 1 deletions
|
@ -1614,7 +1614,7 @@ func (d Decimal) RoundHalfUp(places int32) Decimal {
|
|||
//
|
||||
// NewFromFloat(550).RoundHalfDown(-2).String() // output: "500"
|
||||
// NewFromFloat(560).RoundHalfDown(-2).String() // output: "600"
|
||||
// NewFromFloat(1.1001).RoundHalfDown(2).String() // output: "1.11"
|
||||
// NewFromFloat(1.1001).RoundHalfDown(2).String() // output: "1.10"
|
||||
// NewFromFloat(-1.454).RoundHalfDown(1).String() // output: "-1.5"
|
||||
// NewFromFloat(-1.444).RoundHalfDown(1).String() // output: "-1.4"
|
||||
func (d Decimal) RoundHalfDown(places int32) Decimal {
|
||||
|
|
Loading…
Reference in a new issue