diff options
Diffstat (limited to 'readme.md')
| -rw-r--r-- | readme.md | 22 |
1 files changed, 14 insertions, 8 deletions
@@ -200,7 +200,7 @@ duplicate the two topmost values on the stack. call the error handler (the address of which is in the variable `handler`) -### `again ( -- ) IMMEDIATE` +### `again ( -- ) IMMEDIATE COMPILE-ONLY` complete an infinite loop began by the word `begin`. ### `allot ( u -- )` @@ -213,7 +213,7 @@ perform bitwise AND on u1 and u2. a variable containing the current numeric input/output base. by default this is 10. -### `begin ( -- ) IMMEDIATE` +### `begin ( -- ) IMMEDIATE COMPILE-ONLY` mark the beginning of a begin-again, begin-until, or begin-while-repeat loop. @@ -262,6 +262,12 @@ bytes are copied in high memory to low memory order. ### `compile, ( xt -- )` compile a call to xt into user memory. +### `compile-only ( -- )` +mark the most recently defined word as compile-only. + +### `compile-only? ( ht -- ? )` +true if ht is marked compile-only, false otherwise. + ### `constant ( u "name" -- )` create a word that pushes a cell value u to the stack. @@ -298,7 +304,7 @@ remove the value at the top of the stack. ### `dup ( u -- u u )` duplicate the value at the top of the stack. -### `else ( -- ) IMMEDIATE` +### `else ( -- ) IMMEDIATE COMPILE-ONLY` update the current if statement to branch here when the flag is false, and skip to `then` if the corresponding `if` was true. @@ -332,7 +338,7 @@ yields the address of the first available byte in user memory. ### `hex ( -- )` set current base to hexadecimal. -### `if ( ? -- ) IMMEDIATE` +### `if ( ? -- ) IMMEDIATE COMPILE-ONLY` if the flag is true, execute the following if statement, terminated by `else` or `then`. @@ -393,7 +399,7 @@ move a value from the return stack to the working stack. ### `rdrop ( R: u -- )` remove the value at the top of the return stack. -### `repeat ( -- ) IMMEDIATE` +### `repeat ( -- ) IMMEDIATE COMPILE-ONLY` in a begin-while-repeat loop, loop back to the condition. ### `rot ( u1 u2 u3 -- u2 u3 u1 )` @@ -429,7 +435,7 @@ perform the syscall with the id in `rax`, taking three parameters placed in `rdi`, `rsi` and `rdx`, and push the value of the `rax` register to the stack. -### `then ( -- ) IMMEDIATE` +### `then ( -- ) IMMEDIATE COMPILE-ONLY` conclude an if statement. ### `tib ( -- a )` @@ -441,13 +447,13 @@ a cell with all bits set. ### `type ( a u -- )` write u characters at a to output. -### `until ( ? -- ) IMMEDIATE` +### `until ( ? -- ) IMMEDIATE COMPILE-ONLY` if the given flag is true, loop back to `begin`. ### `variable ( "name" -- )` create a variable word, which yields an address that can be written and read. -### `while ( ? -- ) IMMEDIATE` +### `while ( ? -- ) IMMEDIAT COMPILE-ONLYE` if given flag is true, continue the current begin-while-repeat loop, otherwise branch to after. |
