# int128

Theme:

- Index

Search:
Group by:
Source Edit

This module is for compiler internal use only. For reliable error messages and range checks, the compiler needs a data type that can hold all from `low(BiggestInt)` to `high(BiggestUInt)`, This type is for that purpose.

# Types

    Int128 = object

  Source Edit

# Consts

    NegOne = (udata: [4294967295'u, 4294967295'u, 4294967295'u, 4294967295'u])

  Source Edit

    One = (udata: [1'u, 0'u, 0'u, 0'u])

  Source Edit

    Ten = (udata: [10'u, 0'u, 0'u, 0'u])

  Source Edit

    Zero = (udata: [0'u, 0'u, 0'u, 0'u])

  Source Edit

# Procs

    proc `$`(a: Int128): string {....raises: [], tags: [], forbids: [].}

  Source Edit

    proc `*`(a: Int128; b: int32): Int128 {....raises: [], tags: [], forbids: [].}

  Source Edit

    proc `*`(lhs, rhs: Int128): Int128 {....raises: [], tags: [], forbids: [].}

  Source Edit

    proc `*=`(a: var Int128; b: Int128) {....raises: [], tags: [], forbids: [].}

  Source Edit

    proc `+`(a, b: Int128): Int128 {....raises: [], tags: [], forbids: [].}

  Source Edit

    proc `+`(a: BiggestInt; b: Int128): Int128 {....raises: [], tags: [], forbids: [].}

  Source Edit

    proc `+`(a: Int128; b: BiggestInt): Int128 {....raises: [], tags: [], forbids: [].}

  Source Edit

    proc `+=`(a: var Int128; b: Int128) {....raises: [], tags: [], forbids: [].}

  Source Edit

    proc `-`(a, b: Int128): Int128 {....raises: [], tags: [], forbids: [].}

  Source Edit

    proc `-`(a: BiggestInt; b: Int128): Int128 {....raises: [], tags: [], forbids: [].}

  Source Edit

    proc `-`(a: Int128): Int128 {....raises: [], tags: [], forbids: [].}

  Source Edit

    proc `-`(a: Int128; b: BiggestInt): Int128 {....raises: [], tags: [], forbids: [].}

  Source Edit

    proc `-=`(a: var Int128; b: Int128) {....raises: [], tags: [], forbids: [].}

  Source Edit

    proc `<`(a, b: Int128): bool {....raises: [], tags: [], forbids: [].}

  Source Edit

    proc `<`(a: BiggestInt; b: Int128): bool {....raises: [], tags: [], forbids: [].}

  Source Edit

    proc `<`(a: Int128; b: BiggestInt): bool {....raises: [], tags: [], forbids: [].}

  Source Edit

    proc `<=`(a, b: Int128): bool {....raises: [], tags: [], forbids: [].}

  Source Edit

    proc `<=`(a: BiggestInt; b: Int128): bool {....raises: [], tags: [], forbids: [].}

  Source Edit

    proc `<=`(a: Int128; b: BiggestInt): bool {....raises: [], tags: [], forbids: [].}

  Source Edit

    proc `==`(a, b: Int128): bool {....raises: [], tags: [], forbids: [].}

  Source Edit

    proc `==`(a: BiggestInt; b: Int128): bool {....raises: [], tags: [], forbids: [].}

  Source Edit

    proc `==`(a: Int128; b: BiggestInt): bool {....raises: [], tags: [], forbids: [].}

  Source Edit

    proc abs(a: Int128): Int128 {....raises: [], tags: [], forbids: [].}

  Source Edit

    proc addInt128(result: var string; value: Int128) {....raises: [], tags: [],
        forbids: [].}

  Source Edit

    proc addToHex(result: var string; arg: Int128) {....raises: [], tags: [],
        forbids: [].}

  Source Edit

    proc bitand(a, b: Int128): Int128 {....raises: [], tags: [], forbids: [].}

  Source Edit

    proc bitnot(a: Int128): Int128 {....raises: [], tags: [], forbids: [].}

  Source Edit

    proc bitor(a, b: Int128): Int128 {....raises: [], tags: [], forbids: [].}

  Source Edit

    proc bitxor(a, b: Int128): Int128 {....raises: [], tags: [], forbids: [].}

  Source Edit

    proc castToInt64(arg: Int128): int64 {....raises: [], tags: [], forbids: [].}

  Conversion to int64 without range check. Source Edit

    proc castToUInt64(arg: Int128): uint64 {....raises: [], tags: [], forbids: [].}

  Conversion to uint64 without range check. Source Edit

    proc cmp(a, b: Int128): int {....raises: [], tags: [], forbids: [].}

  Source Edit

    proc `div`(a, b: Int128): Int128 {....raises: [], tags: [], forbids: [].}

  Source Edit

    proc divMod(dividend, divisor: Int128): tuple[quotient, remainder: Int128] {.
        ...raises: [], tags: [], forbids: [].}

  Source Edit

    proc fastLog2(a: Int128): int {....raises: [], tags: [], forbids: [].}

  Source Edit

    proc inc(a: var Int128; y: uint32 = 1) {....raises: [], tags: [], forbids: [].}

  Source Edit

    proc maskBytes(arg: Int128; numbytes: int): Int128 {.noinit, ...raises: [],
        tags: [], forbids: [].}

  Source Edit

    proc maskUInt8(arg: Int128): Int128 {.noinit, inline, ...raises: [], tags: [],
                                          forbids: [].}

  Source Edit

    proc maskUInt16(arg: Int128): Int128 {.noinit, inline, ...raises: [], tags: [],
                                           forbids: [].}

  Source Edit

    proc maskUInt32(arg: Int128): Int128 {.noinit, inline, ...raises: [], tags: [],
                                           forbids: [].}

  Source Edit

    proc maskUInt64(arg: Int128): Int128 {.noinit, inline, ...raises: [], tags: [],
                                           forbids: [].}

  Source Edit

    proc `mod`(a, b: Int128): Int128 {....raises: [], tags: [], forbids: [].}

  Source Edit

    proc parseDecimalInt128(arg: string; pos: int = 0): Int128 {....raises: [],
        tags: [], forbids: [].}

  Source Edit

    proc `shl`(a: Int128; b: int): Int128 {....raises: [], tags: [], forbids: [].}

  Source Edit

    proc `shr`(a: Int128; b: int): Int128 {....raises: [], tags: [], forbids: [].}

  Source Edit

    proc toFloat64(arg: Int128): float64 {....raises: [], tags: [], forbids: [].}

  Source Edit

    proc toHex(arg: Int128): string {....raises: [], tags: [], forbids: [].}

  Source Edit

    proc toInt(arg: Int128): int {....raises: [], tags: [], forbids: [].}

  Source Edit

    proc toInt8(arg: Int128): int8 {....raises: [], tags: [], forbids: [].}

  Source Edit

    proc toInt16(arg: Int128): int16 {....raises: [], tags: [], forbids: [].}

  Source Edit

    proc toInt32(arg: Int128): int32 {....raises: [], tags: [], forbids: [].}

  Source Edit

    proc toInt64(arg: Int128): int64 {....raises: [], tags: [], forbids: [].}

  Source Edit

    proc toInt64Checked(arg: Int128; onError: int64): int64 {....raises: [], tags: [],
        forbids: [].}

  Source Edit

    proc toInt128(arg: float64): Int128 {....raises: [], tags: [], forbids: [].}

  Source Edit

    proc toInt128[T: SomeInteger | bool](arg: T): Int128

  Source Edit

    proc toUInt(arg: Int128): uint {....raises: [], tags: [], forbids: [].}

  Source Edit

    proc toUInt8(arg: Int128): uint8 {....raises: [], tags: [], forbids: [].}

  Source Edit

    proc toUInt16(arg: Int128): uint16 {....raises: [], tags: [], forbids: [].}

  Source Edit

    proc toUInt32(arg: Int128): uint32 {....raises: [], tags: [], forbids: [].}

  Source Edit

    proc toUInt64(arg: Int128): uint64 {....raises: [], tags: [], forbids: [].}

  Source Edit

# Templates

    template high(t: typedesc[Int128]): Int128

  Source Edit

    template low(t: typedesc[Int128]): Int128

  Source Edit