major touch-up into presentable form
[rrq/rrqforth.git] / adoc / p_right_bracket.adoc
index 4f8589d620fbcb9fd0a58c76eccf75b1bc328387..218873a0272c87180ae0a2f308938b9ae1b62d18 100644 (file)
@@ -1,21 +1,27 @@
+compile.asm:   WORD p_right_bracket,']',fasm
+
 anchor:p_right_bracket[]
 
-Word: ]
--------
+=== Word: ]
 
-----
-compile.asm:   WORD p_right_bracket,']',fasm
-----
+....
+Data stack: ( -- )
+....
 
-"]" (right bracket) is function word that sets the stream evaluation
-mode to be compiling. In this mode, words are not executed immediately
-after parsing but rather having their CFA placed on the heap. However,
-words marked as IMMEDIATE (flags&1 != 0) are executed as if
-interpreting mode. Likewise for numbers.
+"]" (right bracket) is a function word that sets the stream evaluation
+mode to be compiling. In this mode words parsed into CFA pointers
+which are placed on the heap in the given order, unless the word is
+flagged as <<p_immediate,IMMEDIATE>> or a <<p_number,NUMBER>>. An
+immediate word is executed immediately, and a number is parsed and
+left on the stack.
+
+Note that a word is parsed as a number only if it is not found in the
+wordlist; i.e., the word list may contain definitions for numbers.
 
-.Execution semantics expressed in RRQFORTH
 ====
-: [ IMMEDIATE 1 STATE ! ;
+.Word: ]
+[caption='Definition concept {counter:exec}: ']
+----
+: ] 1 STATE ! ;
+----
 ====
-
-