decimal

package
v0.0.0-rc9 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 12, 2024 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrSyntax = fmt.Errorf("invalid syntax")

Functions

func IsErr

func IsErr(x *big.Int) bool

IsErr reports whether x is an "error" value.

func IsInf

func IsInf(x *big.Int) bool

IsInf reports whether x is an infinity.

func IsNaN

func IsNaN(x *big.Int) bool

IsNaN reports whether x is a "not-a-number" value.

func Parse

func Parse(s string, precision, scale uint32) (*big.Int, error)

Parse interprets a string s with the given precision and scale and returns the corresponding big integer.

had to copy this function, since it's internal in ydb-driver
see here: https://github.com/ydb-platform/ydb-go-sdk/issues/1435

Types

type ParseError

type ParseError struct {
	Err   error
	Input string
}

func (*ParseError) Error

func (p *ParseError) Error() string

func (*ParseError) Unwrap

func (p *ParseError) Unwrap() error

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL