integers

int8: max, min, compare, print, hash

int16: max, min, compare, print, hash

int32: max, min, compare, print, hash

int64: max, min, compare, print, hash

int128: compare

uint8: max, min, compare, print, hash

uint16: max, min, compare, print, hash

uint32: max, min, compare, print, hash

uint64: max, min, compare, print, hash

c_size_t: compare, print, hash

uint128: compare

struct int8: Copyable, Comparable, Printable, Hashable, Addable

An 8-bit signed integer.

max

const int8 max = 127;

Largest value of this type.

min

const int8 min = -128;

Smallest value of this type.

compare

Ordering compare(int8& other)

Compares this value to another.

print

void print(OutputStream& stream)

Writes this value to the given stream.

hash

uint64 hash()

Returns the hash of this value.

struct int16: Copyable, Comparable, Printable, Hashable, Addable

A 16-bit signed integer.

max

const int16 max = 32767;

Largest value of this type.

min

const int16 min = -32768;

Smallest value of this type.

compare

Ordering compare(int16& other)

Compares this value to another.

print

void print(OutputStream& stream)

Writes this value to the given stream.

hash

uint64 hash()

Returns the hash of this value.

struct int32: Copyable, Comparable, Printable, Hashable, Addable

A 32-bit signed integer.

max

const int32 max = 2147483647;

Largest value of this type.

min

const int32 min = -2147483648;

Smallest value of this type.

compare

Ordering compare(int32& other)

Compares this value to another.

print

void print(OutputStream& stream)

Writes this value to the given stream.

hash

uint64 hash()

Returns the hash of this value.

struct int64: Copyable, Comparable, Printable, Hashable, Addable

A 64-bit signed integer.

max

const int64 max = 9223372036854775807;

Largest value of this type.

min

const int64 min = -9223372036854775808;

Smallest value of this type.

compare

Ordering compare(int64& other)

Compares this value to another.

print

void print(OutputStream& stream)

Writes this value to the given stream.

hash

uint64 hash()

Returns the hash of this value.

struct int128: Copyable, Comparable

A 128-bit signed integer.

compare

Ordering compare(int128& other)

Compares this value to another.

struct uint8: Copyable, Comparable, Printable, Hashable, Addable

An 8-bit unsigned integer.

max

const uint8 max = 255;

Largest value of this type.

min

const uint8 min = 0;

Smallest value of this type.

compare

Ordering compare(uint8& other)

Compares this value to another.

print

void print(OutputStream& stream)

Writes this value to the given stream.

hash

uint64 hash()

Returns the hash of this value.

struct uint16: Copyable, Comparable, Printable, Hashable, Addable

A 16-bit unsigned integer.

max

const uint16 max = 65535;

Largest value of this type.

min

const uint16 min = 0;

Smallest value of this type.

compare

Ordering compare(uint16& other)

Compares this value to another.

print

void print(OutputStream& stream)

Writes this value to the given stream.

hash

uint64 hash()

Returns the hash of this value.

struct uint32: Copyable, Comparable, Printable, Hashable, Addable

A 32-bit unsigned integer.

max

const uint32 max = 4294967295;

Largest value of this type.

min

const uint32 min = 0;

Smallest value of this type.

compare

Ordering compare(uint32& other)

Compares this value to another.

print

void print(OutputStream& stream)

Writes this value to the given stream.

hash

uint64 hash()

Returns the hash of this value.

struct uint64: Copyable, Comparable, Printable, Hashable, Addable

A 64-bit unsigned integer.

max

const uint64 max = 18446744073709551615;

Largest value of this type.

min

const uint64 min = 0;

Smallest value of this type.

compare

Ordering compare(uint64& other)

Compares this value to another.

print

void print(OutputStream& stream)

Writes this value to the given stream.

hash

uint64 hash()

Returns the hash of this value.

struct c_size_t: Copyable, Comparable, Printable, Hashable, Addable

C's size_t type: a pointer-sized unsigned integer, 32-bit on wasm32 and 64-bit on the 64-bit native targets. Use it for C externs that take size_t (e.g. getcwd) so the generated call matches the C headers on every target. (No max/min: the largest value depends on the target.)

compare

Ordering compare(c_size_t& other)

Compares this value to another.

print

void print(OutputStream& stream)

Writes this value to the given stream.

hash

uint64 hash()

Returns the hash of this value.

struct uint128: Copyable, Comparable

A 128-bit unsigned integer.

compare

Ordering compare(uint128& other)

Compares this value to another.