-Word: LIT
----------
+// compile.asm: WORD p_literal,'LIT',fasm
anchor:p_literal[]
-----
-compile.asm: WORD p_literal,'LIT',fasm
-----
-Data stack: compiling ( v -- ) interpreting ( -- v )
+=== Word: LIT
-"LIT" is a function word for, in compiling mode, creating a literal
-value the gets pushed in interpreting mode. In compiling mode, it a
-lays out its own CFA pointer, then grabs the current stack value onto
-the heap. In interpreting mode it recreates the value onto the stack.
+....
+Data stack: ( -- v )
+....
-Note that the value is layed out as if a subsequent CFA poitnter in
-the containing definition, but the LIT execution will make the
-execution skip past that and instead contine with the CFA pointer
-folling the value.
+"LIT" is a function word that pushes the cell subsequent and moves
+excution past that. The literal value is thus layed out as if a
+subsequent CFA pointer in the containing definition, and the LIT
+execution will make the execution skip past that and instead contine
+with the CFA pointer following the value.
It's not a good idea to use "LIT" interactively.
-.Execution semantics expressed in RRQFORTH
====
-: LIT IMMEDIATE
- STATE @ IF p_literal , ELSE R> DUP 8 + >R @ THEN
-;
+.Definition concept for LIT
+****
+: LIT R> DUP 8 + >R @ ;
+****
====