Types
Consts
GCC_Compatible = true
- Source Edit
WordBitWidth = 64
- Source Edit
Procs
func usedBitsAndWords(a: openArray[Word]): tuple[bits, words: int] {....raises: [], inline, noinit, ...gcsafe, tags: [], forbids: [].}
-
Returns the number of used words and bits in a bigInt.
Returns (0, 0) for all-zeros array (even if technically you need 1 bit and 1 word to encode zero).
Source Edit func wordsRequired(bits: int): int {.compileTime, ...raises: [], tags: [], forbids: [].}
- Compute the number of limbs required for the announced bit length. Source Edit