Types
LowerBits = distinct LowerBitsImpl
- tags the last 3 bits of the pointer in place Source Edit
LowerBitsImpl = range[0 .. 7]
- Source Edit
LowerBitsTagged[T] = Tagged[T, LowerBits]
- Source Edit
Procs
proc tagLowerBits[T](val: T; tag: LowerBitsImpl): LowerBitsTagged[T] {.inline.}
- Source Edit
Templates
template getTag[T](tagged: LowerBitsTagged[T]): LowerBitsImpl
- Source Edit
template splitTagInline[T: PointerLike](tagged: Tagged[T, LowerBits]): LowerBits
- Source Edit
template untagInline(tagged: Tagged[uint, LowerBits]): uint
- Source Edit
template untagInline[T: PointerLike](tagged: Tagged[T, LowerBits]): T
- Source Edit
template withTagInline[T: PointerLike](val: T; t: LowerBits): Tagged[T, LowerBits]
- Source Edit