Next:
Memory
, Previous:
Arithmetic
, Up:
Words
5.6 Stack Manipulation
Gforth maintains a number of separate stacks:
A data stack (also known as the
parameter stack
) – for characters, cells, addresses, and double cells.
A floating point stack – for holding floating point (FP) numbers.
A return stack – for holding the return addresses of colon definitions and other (non-FP) data.
A locals stack – for holding local variables.
Data stack
Floating point stack
Return stack
Locals stack
Stack pointer manipulation