Skip to main content

Module cell

Module cell 

Source
Expand description

Tagged 64-bit term words.

The encoding (tag values, the low-3-bits split, functor packing) is the word/cell ABI shared with the compiler, so it lives in plg-shared as the single source of truth — codegen emits the same layout into .rodata fact tables and blobs. Re-exported here so the runtime keeps using crate::cell.

Constants§

INT_MAX
Largest magnitude representable as an immediate integer; values outside box to a TAG_BIG heap cell (full i64 range, v1 parity).
INT_MIN
TAG_ATOM
TAG_BIG
TAG_FLT
TAG_INT
TAG_LST
TAG_REF
TAG_STR

Functions§

atom_id
int_value
Signed payload extraction (arithmetic shift preserves the sign).
make
make_atom
make_int
make_ref
pack_functor
Pack a STR header cell: functor id in the high half, arity in the low.
payload
tag_of
unpack_functor

Type Aliases§

Word