NAME
u64.h - 64bit unsigned integers
SYNOPSIS
#include <limb/u64.h>
DESCRIPTION
This header defines functions allowing to work with 64bit unsigned integers.
Constants
The following constants are defined :
U64_FMT
Maximum length for a byte array that can hold an u64 value in decimal representation, plus a NUL-terminating byte
U64_FMTG
Same as U64_FMT but with thousand-separators
U64_BFMT
Same as U64_FMT but for binary
U64_OFMT
Same as U64_FMT but for octal
U64_XFMT
Same as U64_FMT but for hexadecimal
Functions
The following functions/macros are defined :
Convert a u64 number to big endian.
Convert a u64 number to little endian.
Similar to u64_be(3) but takes a pointer.
Similar to u64_le(3) but takes a pointer.
Similar to u64p_be(3) but for an array of pointers.
Similar to u64p_le(3) but for an array of pointers.
Store a u64 number encoded in little endian.
Read a u64 number encoded in little endian.
Store a u64 number encoded in big endian.
Read a u64 number encoded in big endian.
Store a 64 number encoded in little endian trimming "unneeded" bits.
Read a u64 number encoded in little endian with "unneeded" bits trimmed.
Write a u64 number as decimal into a byte array.
Write a u64 number as decimal, using coma as thousand separator, into a byte array.
Write a u64 number into a byte array, encoded in specified base and optionally grouped using given separator.
Same as u64_fmt_generic(3) but filling with given character if less than given size.
Similar to u64_fmt(3) but as binary.
Similar to u64_fmt(3) but as octal.
Similar to u64_fmt(3) but as hexadecimal.
Similar to u64_fmt(3) but filling with zeroes if less than given size.
Similar to u64_fmtg(3) but filling with zeroes if less than given size.
Similar to u64_bfmt(3) but filling with zeroes if less than given size.
Similar to u64_ofmt(3) but filling with zeroes if less than given size.
Similar to u64_xfmt(3) but filling with zeroes if less than given size.
Read a u64 value from a byte array.
Similar to u64_scan(3) but for binary value.
Similar to u64_scan(3) but for octal value.
Similar to u64_scan(3) but for hexadecimal value.
Similar to u64_scan(3) but expects a NUL-terminated string.
Similar to u64_bscan(3) but expects a NUL-terminated string.
Similar to u64_oscan(3) but expects a NUL-terminated string.
Similar to u64_xscan(3) but expects a NUL-terminated string.