Skip to content

v0.8.4

Compare
Choose a tag to compare
@xpineal xpineal released this 22 Jun 08:32
· 44 commits to main since this release
3c87de3

Add encoding/decoding base16(hex)/base32 method with int64/uin64

  • in package tex
  • functions:
//I64Hex convert int64 to hex(hexadecimal 16-base) string
func I64Hex(i int64) string

//U64Hex convert uint64 to hex(hexadecimal 16-base) string
func U64Hex(u uint64) string

//I64HexV2 convert int64 to 32 base string
func I64HexV2(i int64) string

//U64HexV2 convert uint64 to 32 base string
func U64HexV2(u uint64) string

//HexI64 convert hex string(16-base) to int64
func HexI64(s string) (int64, error)

//HexU64 convert hex string(16-base) to uint64
func HexU64(s string) (uint64, error)

//HexI64V2 convert 32 base string to int64
func HexI64V2(s string) (int64, error)

//HexU64V2 convert 32 base string to uint64
func HexU64V2(s string) (uint64, error)