MCPcopy Create free account
hub / github.com/DOSNetwork/core / Init64

Method Init64

group/mod/int.go:86–91  ·  view source on GitHub ↗

Init64 creates an Int with an int64 value and big.Int modulus.

(v int64, m *big.Int)

Source from the content-addressed store, hash-verified

84
85// Init64 creates an Int with an int64 value and big.Int modulus.
86func (i *Int) Init64(v int64, m *big.Int) *Int {
87 i.M = m
88 i.BO = BigEndian
89 i.V.SetInt64(v).Mod(&i.V, m)
90 return i
91}
92
93// InitBytes init the Int to a number represented in a big-endian byte string.
94func (i *Int) InitBytes(a []byte, m *big.Int, byteOrder ByteOrder) *Int {

Callers 2

TestIntEndiannessFunction · 0.80
NewInt64Function · 0.80

Calls 1

SetInt64Method · 0.45

Tested by 1

TestIntEndiannessFunction · 0.64