Expand description
Bitwise operations and binary visualization functions
This module provides additional bitwise functions not covered by the bigint module. Basic operations like BITAND, BITOR, BITXOR, TO_BINARY, FROM_BINARY are in bigint.
Structs§
- Binary
Format Function - BINARY_FORMAT(n, separator, group_size) - Format binary with separator
- BitNot
Function - BITNOT(a) - Bitwise NOT operation
- Count
Bits Function - COUNT_BITS(n) - Count number of set bits (popcount)
- Highest
BitFunction - HIGHEST_BIT(n) - Returns the position of the highest set bit
- IsPower
OfTwo Function - IS_POWER_OF_TWO(n) - Check if number is exact power of two
- Lowest
BitFunction - LOWEST_BIT(n) - Returns the position of the lowest set bit
- Next
Power OfTwo Function - NEXT_POWER_OF_TWO(n) - Returns the next power of two greater than or equal to n
Functions§
- register_
bitwise_ functions - Register all bitwise functions