Skip to content

Commit

Permalink
Decimal: fix wording in API docs
Browse files Browse the repository at this point in the history
  • Loading branch information
db47h committed May 29, 2020
1 parent 862cdd3 commit dc402a3
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion decimal.go
Original file line number Diff line number Diff line change
Expand Up @@ -829,7 +829,7 @@ func (z *Decimal) Neg(x *Decimal) *Decimal {
return z
}

// Prec returns the mantissa precision of x in bits.
// Prec returns the mantissa precision of x in decimal digits.
// The result may be 0 for |x| == 0 and |x| == Inf.
func (x *Decimal) Prec() uint {
return uint(x.prec)
Expand Down
4 changes: 2 additions & 2 deletions decimal_conv.go
Original file line number Diff line number Diff line change
Expand Up @@ -247,9 +247,9 @@ func (z *Decimal) Parse(s string, base int) (f *Decimal, b int, err error) {
return
}

// ParseDecimal is like f.Parse(s, base) with f set to the given precision
// ParseDecimal is like d.Parse(s, base) with d set to the given precision
// and rounding mode.
func ParseDecimal(s string, base int, prec uint, mode RoundingMode) (f *Decimal, b int, err error) {
func ParseDecimal(s string, base int, prec uint, mode RoundingMode) (d *Decimal, b int, err error) {
return new(Decimal).SetPrec(prec).SetMode(mode).Parse(s, base)
}

Expand Down

0 comments on commit dc402a3

Please sign in to comment.