All Scheme object is either a pointer to a cell or an immediate small integer
All non immediate QScheme objects are stored in a heap, which is simply an array of Sobject
structure. A Sobject structure contains the following fields:
If a type needs more data than the 2 pointers space provided, it has to allocate more space in the system heap by using the scm_must_alloc and scm_free functions.
Immediate small integer have bit 0 set to 1. The other bits of the word contain the true integer value. So on a machine where pointer are on 32 bits, the immediate number are coded on 31 bits.
Procedure is implemented as follow:
<envFrame> = <next> <nslots> <bindings>
<code> = <envList> <size> <nargs> <optargs> <code-slot> ...
The envList is a pointer to the symbolic representation of environment as build at compile time. The compile time environment is a list of localvar symbols.