INNER CODE UNIT · Go

func

ericlagergren/decimal · big.go:198

func (z *Big) Canonical(x *Big) *Big {
	return z.Copy(x)
}

// CheckNaNs checks if either x or y is NaN.
//
// If so, it follows the rules of NaN handling set forth in the
// GDA specification. The argument y may be nil. It reports
// whether either condition is a NaN.
func (z *Big) CheckNaNs(x, y *Big) bool {
	return z.invalidContext(z.Context) || z.checkNaNs(x, y, 0)
}

func (z *Big) checkNaNs(x, y *Big, op Payload) bool {
	var yform form
	if y != nil {
		yform = y.form
	}

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…