Documentation ¶
Index ¶
- Constants
- func FormatInt128(i Int128, base int) string
- func FormatUint128(i Uint128, base int) string
- func Gop_istmp(a interface{}) bool
- type Bigfloat
- type Bigint
- func Bigint_Cast__0(x int) Bigint
- func Bigint_Cast__1(x UntypedBigint) Bigint
- func Bigint_Cast__2(x int64) Bigint
- func Bigint_Cast__3(x uint64) Bigint
- func Bigint_Cast__4(x uint) Bigint
- func Bigint_Cast__5(x *big.Int) Bigint
- func Bigint_Cast__6(x *big.Rat) Bigint
- func Bigint_Cast__7() Bigint
- func Bigint_Init__0(x int) Bigint
- func Bigint_Init__1(x UntypedBigint) Bigint
- func Bigint_Init__2(x *big.Int) Bigint
- func (a Bigint) Gop_Add(b Bigint) Bigint
- func (a Bigint) Gop_AddAssign(b Bigint)
- func (a Bigint) Gop_And(b Bigint) Bigint
- func (a Bigint) Gop_AndAssign(b Bigint)
- func (a Bigint) Gop_AndNot(b Bigint) Bigint
- func (a Bigint) Gop_AndNotAssign(b Bigint)
- func (a Bigint) Gop_Dec()
- func (a Bigint) Gop_Dup() Bigint
- func (a Bigint) Gop_EQ(b Bigint) bool
- func (a Bigint) Gop_GE(b Bigint) bool
- func (a Bigint) Gop_GT(b Bigint) bool
- func (a Bigint) Gop_Inc()
- func (a Bigint) Gop_LE(b Bigint) bool
- func (a Bigint) Gop_LT(b Bigint) bool
- func (a Bigint) Gop_Lsh(n Gop_ninteger) Bigint
- func (a Bigint) Gop_LshAssign(n Gop_ninteger)
- func (a Bigint) Gop_Mul(b Bigint) Bigint
- func (a Bigint) Gop_MulAssign(b Bigint)
- func (a Bigint) Gop_NE(b Bigint) bool
- func (a Bigint) Gop_Neg() Bigint
- func (a Bigint) Gop_Not() Bigint
- func (a Bigint) Gop_Or(b Bigint) Bigint
- func (a Bigint) Gop_OrAssign(b Bigint)
- func (a Bigint) Gop_Quo(b Bigint) Bigint
- func (a Bigint) Gop_QuoAssign(b Bigint)
- func (a Bigint) Gop_Rcast__0() int64
- func (a Bigint) Gop_Rcast__1() (int64, bool)
- func (a Bigint) Gop_Rcast__2() uint64
- func (a Bigint) Gop_Rcast__3() (uint64, bool)
- func (a Bigint) Gop_Rem(b Bigint) Bigint
- func (a Bigint) Gop_RemAssign(b Bigint)
- func (a Bigint) Gop_Rsh(n Gop_ninteger) Bigint
- func (a Bigint) Gop_RshAssign(n Gop_ninteger)
- func (a Bigint) Gop_Sub(b Bigint) Bigint
- func (a Bigint) Gop_SubAssign(b Bigint)
- func (a Bigint) Gop_Xor(b Bigint) Bigint
- func (a Bigint) Gop_XorAssign(b Bigint)
- func (a Bigint) IsNil() bool
- type Bigrat
- func Bigrat_Cast__0(x int) Bigrat
- func Bigrat_Cast__1(a UntypedBigint) Bigrat
- func Bigrat_Cast__2(a *big.Int) Bigrat
- func Bigrat_Cast__3(a Bigint) Bigrat
- func Bigrat_Cast__4(a *big.Rat) Bigrat
- func Bigrat_Cast__5() Bigrat
- func Bigrat_Cast__6(a, b int64) Bigrat
- func Bigrat_Init__0(x int) Bigrat
- func Bigrat_Init__1(x UntypedBigint) Bigrat
- func Bigrat_Init__2(x *big.Rat) Bigrat
- func (a Bigrat) Gop_Add(b Bigrat) Bigrat
- func (a Bigrat) Gop_AddAssign(b Bigrat)
- func (a Bigrat) Gop_Assign(b Bigrat)
- func (a Bigrat) Gop_Dup() Bigrat
- func (a Bigrat) Gop_EQ(b Bigrat) bool
- func (a Bigrat) Gop_GE(b Bigrat) bool
- func (a Bigrat) Gop_GT(b Bigrat) bool
- func (a Bigrat) Gop_Inv() Bigrat
- func (a Bigrat) Gop_LE(b Bigrat) bool
- func (a Bigrat) Gop_LT(b Bigrat) bool
- func (a Bigrat) Gop_Mul(b Bigrat) Bigrat
- func (a Bigrat) Gop_MulAssign(b Bigrat)
- func (a Bigrat) Gop_NE(b Bigrat) bool
- func (a Bigrat) Gop_Neg() Bigrat
- func (a Bigrat) Gop_Quo(b Bigrat) Bigrat
- func (a Bigrat) Gop_QuoAssign(b Bigrat)
- func (a Bigrat) Gop_Sub(b Bigrat) Bigrat
- func (a Bigrat) Gop_SubAssign(b Bigrat)
- func (a Bigrat) IsNil() bool
- type Gop_ninteger
- type Int128
- func Int128_Cast__0(v int) Int128
- func Int128_Cast__1(v UntypedBigint) (out Int128)
- func Int128_Cast__2(v int64) (out Int128)
- func Int128_Cast__3(v uint64) Int128
- func Int128_Cast__4(v int32) Int128
- func Int128_Cast__5(v int16) Int128
- func Int128_Cast__6(v int8) Int128
- func Int128_Cast__7(v Uint128) (out Int128)
- func Int128_Cast__8(v *big.Int) Int128
- func Int128_Cast__9(v *big.Int) (out Int128, inRange bool)
- func Int128_Cast__a() Int128
- func Int128_Init__0(v int) (out Int128)
- func Int128_Init__1(v UntypedBigint) (out Int128)
- func ParseInt128(s string, base int) (out Int128, err error)
- func (i Int128) AbsU() Uint128
- func (i Int128) Abs__0() Int128
- func (i Int128) Abs__1() (ret Int128, inRange bool)
- func (i Int128) BigInt() *big.Int
- func (i Int128) Cmp__0(n int64) int
- func (i Int128) Cmp__1(n Int128) int
- func (i Int128) Format(s fmt.State, c rune)
- func (i *Int128) Gop_AddAssign(b Int128)
- func (i Int128) Gop_Add__0(n int64) (v Int128)
- func (i Int128) Gop_Add__1(n Int128) (v Int128)
- func (i Int128) Gop_And(n Int128) Int128
- func (i *Int128) Gop_AndAssign(b Int128)
- func (i Int128) Gop_AndNot(n Int128) Int128
- func (i *Int128) Gop_AndNotAssign(b Int128)
- func (i *Int128) Gop_Dec()
- func (i Int128) Gop_Dup() (v Int128)
- func (i Int128) Gop_EQ__0(n int64) bool
- func (i Int128) Gop_EQ__1(n Int128) bool
- func (i Int128) Gop_GE__0(n int64) bool
- func (i Int128) Gop_GE__1(n Int128) bool
- func (i Int128) Gop_GT__0(n int64) bool
- func (i Int128) Gop_GT__1(n Int128) bool
- func (i *Int128) Gop_Inc()
- func (i Int128) Gop_LE__0(n int64) bool
- func (i Int128) Gop_LE__1(n Int128) bool
- func (i Int128) Gop_LT__0(n int64) bool
- func (i Int128) Gop_LT__1(n Int128) bool
- func (i Int128) Gop_Lsh(n Gop_ninteger) Int128
- func (i *Int128) Gop_LshAssign(n Gop_ninteger)
- func (i *Int128) Gop_MulAssign(b Int128)
- func (i Int128) Gop_Mul__0(n int64) Int128
- func (i Int128) Gop_Mul__1(n Int128) (dest Int128)
- func (i Int128) Gop_Neg() (v Int128)
- func (i Int128) Gop_Not() Int128
- func (i Int128) Gop_Or(n Int128) Int128
- func (i *Int128) Gop_OrAssign(b Int128)
- func (i *Int128) Gop_QuoAssign(b Int128)
- func (i Int128) Gop_Quo__0(by int64) (q Int128)
- func (i Int128) Gop_Quo__1(by Int128) (q Int128)
- func (i Int128) Gop_Rcast__0() Uint128
- func (i Int128) Gop_Rcast__1() (out Uint128, inRange bool)
- func (i Int128) Gop_Rcast__2() int64
- func (i Int128) Gop_Rcast__3() (out int64, inRange bool)
- func (i Int128) Gop_Rcast__4() uint64
- func (i Int128) Gop_Rcast__5() (out uint64, inRange bool)
- func (i *Int128) Gop_RemAssign(b Int128)
- func (i Int128) Gop_Rem__0(by int64) (r Int128)
- func (i Int128) Gop_Rem__1(by Int128) (r Int128)
- func (i Int128) Gop_Rsh(n Gop_ninteger) Int128
- func (i *Int128) Gop_RshAssign(n Gop_ninteger)
- func (i *Int128) Gop_SubAssign(b Int128)
- func (i Int128) Gop_Sub__0(n int64) (v Int128)
- func (i Int128) Gop_Sub__1(n Int128) (v Int128)
- func (i Int128) Gop_Xor(v Int128) Int128
- func (i *Int128) Gop_XorAssign(b Int128)
- func (i Int128) IsZero() bool
- func (i Int128) QuoRem__0(by int64) (q, r Int128)
- func (i Int128) QuoRem__1(by Int128) (q, r Int128)
- func (i *Int128) Scan(state fmt.ScanState, verb rune) (err error)
- func (i Int128) Sign() int
- func (i Int128) String() string
- func (i Int128) Text(base int) string
- func (i Int128) ToBigInt(b *big.Int)
- type Uint128
- func ParseUint128(s string, base int) (out Uint128, err error)
- func Uint128_Cast__0(v int) Uint128
- func Uint128_Cast__1(v UntypedBigint) Uint128
- func Uint128_Cast__2(v uint64) Uint128
- func Uint128_Cast__3(v uint32) Uint128
- func Uint128_Cast__4(v uint16) Uint128
- func Uint128_Cast__5(v uint8) Uint128
- func Uint128_Cast__6(v int64) (out Uint128)
- func Uint128_Cast__7(v int64) (out Uint128, inRange bool)
- func Uint128_Cast__8(v *big.Int) Uint128
- func Uint128_Cast__9(v *big.Int) (out Uint128, inRange bool)
- func Uint128_Cast__a() Uint128
- func Uint128_Cast__b(v uint) Uint128
- func Uint128_Cast__c(hi, lo uint64) Uint128
- func Uint128_Init__0(v int) (out Uint128)
- func Uint128_Init__1(v UntypedBigint) (out Uint128)
- func (u Uint128) BigInt() *big.Int
- func (u Uint128) Bit(i int) uint
- func (u Uint128) BitLen() int
- func (u Uint128) Cmp__0(n uint64) int
- func (u Uint128) Cmp__1(n Uint128) int
- func (u Uint128) Format(s fmt.State, c rune)
- func (u *Uint128) Gop_AddAssign(b Uint128)
- func (u Uint128) Gop_Add__0(n uint64) (v Uint128)
- func (u Uint128) Gop_Add__1(n Uint128) (v Uint128)
- func (u *Uint128) Gop_AndAssign(b Uint128)
- func (u Uint128) Gop_AndNot(n Uint128) Uint128
- func (u *Uint128) Gop_AndNotAssign(b Uint128)
- func (u Uint128) Gop_And__0(n uint64) Uint128
- func (u Uint128) Gop_And__1(n Uint128) Uint128
- func (u *Uint128) Gop_Dec()
- func (u Uint128) Gop_Dup() (v Uint128)
- func (u Uint128) Gop_EQ__0(n uint64) bool
- func (u Uint128) Gop_EQ__1(n Uint128) bool
- func (u Uint128) Gop_GE__0(n uint64) bool
- func (u Uint128) Gop_GE__1(n Uint128) bool
- func (u Uint128) Gop_GT__0(n uint64) bool
- func (u Uint128) Gop_GT__1(n Uint128) bool
- func (u *Uint128) Gop_Inc()
- func (u Uint128) Gop_LE__0(n uint64) bool
- func (u Uint128) Gop_LE__1(n Uint128) bool
- func (u Uint128) Gop_LT__0(n uint64) bool
- func (u Uint128) Gop_LT__1(n Uint128) bool
- func (u Uint128) Gop_Lsh(n Gop_ninteger) Uint128
- func (u *Uint128) Gop_LshAssign(n Gop_ninteger)
- func (u *Uint128) Gop_MulAssign(b Uint128)
- func (u Uint128) Gop_Mul__0(n uint64) (dest Uint128)
- func (u Uint128) Gop_Mul__1(n Uint128) Uint128
- func (u Uint128) Gop_Not() Uint128
- func (u *Uint128) Gop_OrAssign(b Uint128)
- func (u Uint128) Gop_Or__0(n uint64) Uint128
- func (u Uint128) Gop_Or__1(n Uint128) Uint128
- func (u *Uint128) Gop_QuoAssign(b Uint128)
- func (u Uint128) Gop_Quo__0(by uint64) (q Uint128)
- func (u Uint128) Gop_Quo__1(by Uint128) (q Uint128)
- func (u Uint128) Gop_Rcast__0() float64
- func (u Uint128) Gop_Rcast__1() uint64
- func (u Uint128) Gop_Rcast__2() (out uint64, inRange bool)
- func (u Uint128) Gop_Rcast__3() int64
- func (u Uint128) Gop_Rcast__4() (out int64, inRange bool)
- func (u *Uint128) Gop_RemAssign(b Uint128)
- func (u Uint128) Gop_Rem__0(by uint64) (r Uint128)
- func (u Uint128) Gop_Rem__1(by Uint128) (r Uint128)
- func (u Uint128) Gop_Rsh(n Gop_ninteger) Uint128
- func (u *Uint128) Gop_RshAssign(n Gop_ninteger)
- func (u *Uint128) Gop_SubAssign(b Uint128)
- func (u Uint128) Gop_Sub__0(n uint64) (v Uint128)
- func (u Uint128) Gop_Sub__1(n Uint128) (v Uint128)
- func (u *Uint128) Gop_XorAssign(b Uint128)
- func (u Uint128) Gop_Xor__0(v uint64) Uint128
- func (u Uint128) Gop_Xor__1(v Uint128) Uint128
- func (u Uint128) IsZero() bool
- func (u Uint128) LeadingZeros() int
- func (u Uint128) OnesCount() int
- func (u Uint128) QuoRem__0(by uint64) (q, r Uint128)
- func (u Uint128) QuoRem__1(by Uint128) (q, r Uint128)
- func (u Uint128) Reverse() Uint128
- func (u Uint128) ReverseBytes() Uint128
- func (u *Uint128) Scan(state fmt.ScanState, verb rune) (err error)
- func (u Uint128) SetBit(i int, b uint) (out Uint128)
- func (u Uint128) String() string
- func (u Uint128) Text(base int) string
- func (u Uint128) ToBigInt(b *big.Int)
- func (u Uint128) TrailingZeros() int
- type UntypedBigfloat
- type UntypedBigfloat_Default
- type UntypedBigint
- type UntypedBigint_Default
- type UntypedBigrat
- type UntypedBigrat_Default
Constants ¶
const ( Int128_Max = 1<<127 - 1 Int128_Min = -1 << 127 Int128_IsUntyped = true )
const ( Uint128_Max = 1<<128 - 1 Uint128_Min = 0 Uint128_IsUntyped = true )
const (
GopPackage = true // to indicate this is a Go+ package
)
Variables ¶
This section is empty.
Functions ¶
func FormatInt128 ¶
func FormatUint128 ¶
Types ¶
type Bigfloat ¶
A Bigfloat represents a multi-precision floating point number. The zero value for a Float represents nil.
type Bigint ¶
A Bigint represents a signed multi-precision integer. The zero value for a Bigint represents nil.
func Bigint_Cast__0 ¶
Bigint_Cast: func bigint(x untyped_int) bigint
func Bigint_Cast__1 ¶
func Bigint_Cast__1(x UntypedBigint) Bigint
Bigint_Cast: func bigint(x untyped_bigint) bigint
func Bigint_Cast__3 ¶
Bigint_Cast: func bigint(x uint64) bigint
func Bigint_Cast__5 ¶
Bigint_Cast: func bigint(x *big.Int) bigint
func Bigint_Cast__6 ¶
Bigint_Cast: func bigint(x *big.Rat) bigint
func Bigint_Init__1 ¶
func Bigint_Init__1(x UntypedBigint) Bigint
Bigint_Init: func bigint.init(x untyped_bigint) bigint
func Bigint_Init__2 ¶
Bigint_Init: func bigint.init(x *big.Int) bigint
func (Bigint) Gop_AddAssign ¶
Gop_AddAssign: func (a bigint) += (b bigint)
func (Bigint) Gop_AndAssign ¶
Gop_AndAssign: func (a bigint) &= (b bigint)
func (Bigint) Gop_AndNot ¶
Gop_AndNot: func (a bigint) &^ (b bigint) bigint
func (Bigint) Gop_AndNotAssign ¶
Gop_AndNotAssign: func (a bigint) &^= (b bigint)
func (Bigint) Gop_Lsh ¶
func (a Bigint) Gop_Lsh(n Gop_ninteger) Bigint
Gop_Lsh: func (a bigint) << (n untyped_uint) bigint
func (Bigint) Gop_LshAssign ¶
func (a Bigint) Gop_LshAssign(n Gop_ninteger)
Gop_LshAssign: func (a bigint) <<= (n untyped_uint)
func (Bigint) Gop_MulAssign ¶
Gop_MulAssign: func (a bigint) *= (b bigint)
func (Bigint) Gop_OrAssign ¶
Gop_OrAssign: func (a bigint) |= (b bigint)
func (Bigint) Gop_QuoAssign ¶
Gop_QuoAssign: func (a bigint) /= (b bigint) {
func (Bigint) Gop_Rcast__0 ¶
Gop_Rcast: func int64(x bigint) int64
func (Bigint) Gop_Rcast__1 ¶
Gop_Rcast: func int64(x bigint) (int64, bool)
func (Bigint) Gop_Rcast__2 ¶
Gop_Rcast: func uint64(x bigint) uint64
func (Bigint) Gop_Rcast__3 ¶
Gop_Rcast: func uint64(x bigint) (uint64, bool)
func (Bigint) Gop_RemAssign ¶
Gop_RemAssign: func (a bigint) %= (b bigint)
func (Bigint) Gop_Rsh ¶
func (a Bigint) Gop_Rsh(n Gop_ninteger) Bigint
Gop_Rsh: func (a bigint) >> (n untyped_uint) bigint
func (Bigint) Gop_RshAssign ¶
func (a Bigint) Gop_RshAssign(n Gop_ninteger)
Gop_RshAssign: func (a bigint) >>= (n untyped_uint)
func (Bigint) Gop_SubAssign ¶
Gop_SubAssign: func (a bigint) -= (b bigint)
func (Bigint) Gop_XorAssign ¶
Gop_XorAssign: func (a bigint) ^= (b bigint)
type Bigrat ¶
A Bigrat represents a quotient a/b of arbitrary precision. The zero value for a Bigrat represents nil.
func Bigrat_Cast__0 ¶
Bigrat_Cast: func bigrat(x untyped_int) bigrat
func Bigrat_Cast__1 ¶
func Bigrat_Cast__1(a UntypedBigint) Bigrat
Bigrat_Cast: func bigrat(a untyped_bigint) bigrat
func Bigrat_Cast__2 ¶
Bigrat_Cast: func bigrat(a *big.Int) bigrat
func Bigrat_Cast__3 ¶
Bigrat_Cast: func bigrat(a bigint) bigrat
func Bigrat_Cast__4 ¶
Bigrat_Cast: func bigrat(a *big.Rat) bigrat
func Bigrat_Cast__6 ¶
Bigrat_Cast: func bigrat(a, b int64) bigrat
func Bigrat_Init__0 ¶
Bigrat_Init: func bigrat.init(x untyped_int) bigrat
func Bigrat_Init__1 ¶
func Bigrat_Init__1(x UntypedBigint) Bigrat
Bigrat_Init: func bigrat.init(x untyped_bigint) bigrat
func Bigrat_Init__2 ¶
Bigrat_Init: func bigrat.init(x *big.Rat) bigrat
func (Bigrat) Gop_AddAssign ¶
Gop_Add: func (a bigrat) += (b bigrat)
func (Bigrat) Gop_Assign ¶
Gop_Assign: func (a bigrat) = (b bigrat)
func (Bigrat) Gop_MulAssign ¶
Gop_Mul: func (a bigrat) *= (b bigrat)
func (Bigrat) Gop_QuoAssign ¶
Gop_Quo: func (a bigrat) /= (b bigrat)
func (Bigrat) Gop_SubAssign ¶
Gop_Sub: func (a bigrat) -= (b bigrat)
type Gop_ninteger ¶
type Gop_ninteger = uint
type Int128 ¶
type Int128 struct {
// contains filtered or unexported fields
}
func Int128_Cast__1 ¶
func Int128_Cast__1(v UntypedBigint) (out Int128)
Int128_Cast: func int128(v untyped_bigint) int128
func Int128_Cast__2 ¶
Int128_Cast: func int128(v int64) int128
func Int128_Cast__3 ¶
Int128_Cast: func int128(v uint64) int128
func Int128_Cast__7 ¶
Int128_Cast: func int128(v uint18) int128
func Int128_Cast__8 ¶
Int128_Cast: func int128(v *big.Int) int128
func Int128_Init__0 ¶
Int128_Init: func int128.init(v int) int128
func Int128_Init__1 ¶
func Int128_Init__1(v UntypedBigint) (out Int128)
Int128_Init: func int128.init(v untyped_bigint) int128
func (Int128) AbsU ¶
AbsU returns the absolute value of i as an unsigned integer. All values of i are representable using this function, but the type is changed.
func (Int128) Cmp__0 ¶
Cmp64 compares 'i' to 64-bit int 'n' and returns:
< 0 if i < n 0 if i == n > 0 if i > n
The specific value returned by Cmp is undefined, but it is guaranteed to satisfy the above constraints.
func (Int128) Cmp__1 ¶
Cmp compares i to n and returns:
< 0 if i < n 0 if i == n > 0 if i > n
The specific value returned by Cmp is undefined, but it is guaranteed to satisfy the above constraints.
func (*Int128) Gop_AddAssign ¶
Gop_AddAssign: func (a *int128) += (b int128)
func (Int128) Gop_Add__0 ¶
func (Int128) Gop_Add__1 ¶
func (*Int128) Gop_AndAssign ¶
Gop_AndAssign: func (a *int128) &= (b int128)
func (Int128) Gop_AndNot ¶
func (*Int128) Gop_AndNotAssign ¶
Gop_AndNotAssign: func (a *int128) &^= (b int128)
func (Int128) Gop_Lsh ¶
func (i Int128) Gop_Lsh(n Gop_ninteger) Int128
func (*Int128) Gop_LshAssign ¶
func (i *Int128) Gop_LshAssign(n Gop_ninteger)
Gop_LshAssign: func (a *int128) <<= (n untyped_uint)
func (*Int128) Gop_MulAssign ¶
Gop_MulAssign: func (a *int128) *= (b int128)
func (Int128) Gop_Mul__0 ¶
func (Int128) Gop_Mul__1 ¶
Mul returns the product of two I128s.
Overflow should wrap around, as per the Go spec.
func (*Int128) Gop_OrAssign ¶
Gop_OrAssign: func (a *int128) |= (b int128)
func (*Int128) Gop_QuoAssign ¶
Gop_QuoAssign: func (a *int128) /= (b int128) {
func (Int128) Gop_Quo__0 ¶
func (Int128) Gop_Quo__1 ¶
Quo returns the quotient x/y for y != 0. If y == 0, a division-by-zero run-time panic occurs. Quo implements truncated division (like Go); see QuoRem for more details.
func (Int128) Gop_Rcast__0 ¶
Gop_Rcast: func uint128(v int128) uint128
func (Int128) Gop_Rcast__1 ¶
Gop_Rcast: func uint128(v int128) (uint128, bool)
func (Int128) Gop_Rcast__2 ¶
Gop_Rcast: func int64(v int128) int64
func (Int128) Gop_Rcast__3 ¶
Gop_Rcast: func int64(v int128) (int64, bool)
func (Int128) Gop_Rcast__4 ¶
Gop_Rcast: func uint64(v int128) uint64
func (Int128) Gop_Rcast__5 ¶
Gop_Rcast: func uint64(v int128) (uint64, bool)
func (*Int128) Gop_RemAssign ¶
Gop_RemAssign: func (a *int128) %= (b int128)
func (Int128) Gop_Rem__0 ¶
func (Int128) Gop_Rem__1 ¶
Gop_Rem returns the remainder of x%y for y != 0. If y == 0, a division-by-zero run-time panic occurs. Gop_Rem implements truncated modulus (like Go); see QuoRem for more details.
func (Int128) Gop_Rsh ¶
func (i Int128) Gop_Rsh(n Gop_ninteger) Int128
func (*Int128) Gop_RshAssign ¶
func (i *Int128) Gop_RshAssign(n Gop_ninteger)
Gop_RshAssign: func (a *int128) >>= (n untyped_uint)
func (*Int128) Gop_SubAssign ¶
Gop_SubAssign: func (a *int128) -= (b int128)
func (Int128) Gop_Sub__0 ¶
func (Int128) Gop_Sub__1 ¶
func (*Int128) Gop_XorAssign ¶
Gop_XorAssign: func (a *int128) ^= (b int128)
func (Int128) QuoRem__1 ¶
QuoRem returns the quotient q and remainder r for y != 0. If y == 0, a division-by-zero run-time panic occurs.
QuoRem implements T-division and modulus (like Go):
q = x/y with the result truncated to zero r = x - y*q
U128 does not support big.Int.DivMod()-style Euclidean division.
Note: dividing MinI128 by -1 will overflow, returning MinI128, as per the Go spec (https://golang.org/ref/spec#Integer_operators):
The one exception to this rule is that if the dividend x is the most negative value for the int type of x, the quotient q = x / -1 is equal to x (and r = 0) due to two's-complement integer overflow.
type Uint128 ¶
type Uint128 struct {
// contains filtered or unexported fields
}
func Uint128_Cast__0 ¶
Uint128_Cast: func uint128(v untyped_int) uint128
func Uint128_Cast__1 ¶
func Uint128_Cast__1(v UntypedBigint) Uint128
Uint128_Cast: func uint128(v untyped_bigint) uint128
func Uint128_Cast__2 ¶
Uint128_Cast: func uint128(v uint64) uint128
func Uint128_Cast__3 ¶
Uint128_Cast: func uint128(v uint32) uint128
func Uint128_Cast__4 ¶
Uint128_Cast: func uint128(v uint16) uint128
func Uint128_Cast__5 ¶
Uint128_Cast: func uint128(v uint8) uint128
func Uint128_Cast__6 ¶
Uint128_Cast: func uint128(v int64) uint128
func Uint128_Cast__7 ¶
Uint128_Cast: func uint128(v int64) (uint128, bool)
func Uint128_Cast__8 ¶
Uint128_Cast: func uint128(v *big.Int) uint128
func Uint128_Cast__9 ¶
Uint128_Cast: func uint128(v *big.Int) (uint128, bool)
func Uint128_Cast__b ¶
Uint128_Cast: func uint128(v uint) uint128
func Uint128_Cast__c ¶
Uint128_Cast: func uint128(hi, lo uint64) uint128
func Uint128_Init__0 ¶
Uint128_Init: func uint128.init(v int) uint128
func Uint128_Init__1 ¶
func Uint128_Init__1(v UntypedBigint) (out Uint128)
Uint128_Init: func bigint.init(v untyped_bigint) bigint
func (Uint128) Bit ¶
Bit returns the value of the i'th bit of x. That is, it returns (x>>i)&1. The bit index i must be 0 <= i < 128
func (Uint128) BitLen ¶
BitLen returns the length of the absolute value of u in bits. The bit length of 0 is 0.
func (Uint128) Cmp__1 ¶
Cmp compares 'u' to 'n' and returns:
< 0 if u < n 0 if u == n > 0 if u > n
The specific value returned by Cmp is undefined, but it is guaranteed to satisfy the above constraints.
func (*Uint128) Gop_AddAssign ¶
Gop_AddAssign: func (a *uint128) += (b uint128)
func (Uint128) Gop_Add__0 ¶
func (Uint128) Gop_Add__1 ¶
func (*Uint128) Gop_AndAssign ¶
Gop_AndAssign: func (a *uint128) &= (b uint128)
func (Uint128) Gop_AndNot ¶
func (*Uint128) Gop_AndNotAssign ¶
Gop_AndNotAssign: func (a *uint128) &^= (b uint128)
func (Uint128) Gop_And__0 ¶
func (Uint128) Gop_And__1 ¶
func (Uint128) Gop_Lsh ¶
func (u Uint128) Gop_Lsh(n Gop_ninteger) Uint128
func (*Uint128) Gop_LshAssign ¶
func (u *Uint128) Gop_LshAssign(n Gop_ninteger)
Gop_LshAssign: func (a *uint128) <<= (n untyped_uint)
func (*Uint128) Gop_MulAssign ¶
Gop_MulAssign: func (a *uint128) *= (b uint128)
func (Uint128) Gop_Mul__0 ¶
func (Uint128) Gop_Mul__1 ¶
func (*Uint128) Gop_OrAssign ¶
Gop_OrAssign: func (a *uint128) |= (b uint128)
func (*Uint128) Gop_QuoAssign ¶
Gop_QuoAssign: func (a *uint128) /= (b uint128) {
func (Uint128) Gop_Quo__0 ¶
func (Uint128) Gop_Quo__1 ¶
func (Uint128) Gop_Rcast__0 ¶
Gop_Rcast: func float64(v uint128) float64
func (Uint128) Gop_Rcast__1 ¶
Gop_Rcast: func uint64(v uint128) uint64
func (Uint128) Gop_Rcast__2 ¶
Gop_Rcast: func uint64(v uint128) (uint64, bool)
func (Uint128) Gop_Rcast__3 ¶
Gop_Rcast: func int64(v uint128) int64
func (Uint128) Gop_Rcast__4 ¶
Gop_Rcast: func int64(v uint128) (int64, bool)
func (*Uint128) Gop_RemAssign ¶
Gop_RemAssign: func (a *uint128) %= (b uint128)
func (Uint128) Gop_Rem__0 ¶
func (Uint128) Gop_Rem__1 ¶
Gop_Rem: func (a uint128) % (b uint128) uint128
func (Uint128) Gop_Rsh ¶
func (u Uint128) Gop_Rsh(n Gop_ninteger) Uint128
func (*Uint128) Gop_RshAssign ¶
func (u *Uint128) Gop_RshAssign(n Gop_ninteger)
Gop_RshAssign: func (a *uint128) >>= (n untyped_uint)
func (*Uint128) Gop_SubAssign ¶
Gop_SubAssign: func (a *uint128) -= (b uint128)
func (Uint128) Gop_Sub__0 ¶
func (Uint128) Gop_Sub__1 ¶
func (*Uint128) Gop_XorAssign ¶
Gop_XorAssign: func (a *uint128) ^= (b uint128)
func (Uint128) Gop_Xor__0 ¶
func (Uint128) Gop_Xor__1 ¶
func (Uint128) LeadingZeros ¶
func (Uint128) ReverseBytes ¶
func (Uint128) SetBit ¶
SetBit returns a Uint128 with u's i'th bit set to b (0 or 1). If b is not 0 or 1, SetBit will panic. If i < 0, SetBit will panic.
func (Uint128) TrailingZeros ¶
type UntypedBigfloat ¶
type UntypedBigfloat_Default ¶
type UntypedBigfloat_Default = Bigfloat
type UntypedBigint ¶
func UntypedBigint_Init__0 ¶
func UntypedBigint_Init__0(x int) UntypedBigint
type UntypedBigint_Default ¶
type UntypedBigint_Default = Bigint
type UntypedBigrat ¶
func UntypedBigrat_Init__0 ¶
func UntypedBigrat_Init__0(x int) UntypedBigrat
func UntypedBigrat_Init__1 ¶
func UntypedBigrat_Init__1(x UntypedBigint) UntypedBigrat
type UntypedBigrat_Default ¶
type UntypedBigrat_Default = Bigrat