summaryrefslogtreecommitdiff
path: root/readme.md
diff options
context:
space:
mode:
authorkitty <nepeta@canaglie.net>2026-03-24 14:17:59 +1100
committerkitty <nepeta@canaglie.net>2026-03-24 14:17:59 +1100
commit6819ca743193bb9ae4e32c9c87c98b27d06c0c82 (patch)
treeb44746d48e4fec00241bae78e34bc2f234c32209 /readme.md
parentae1c341e4ce177a83fa678615103f32677888ed8 (diff)
fix s" also rp sp and emit
Diffstat (limited to 'readme.md')
-rw-r--r--readme.md13
1 files changed, 13 insertions, 0 deletions
diff --git a/readme.md b/readme.md
index 00f79dd..beb2a86 100644
--- a/readme.md
+++ b/readme.md
@@ -321,6 +321,9 @@ update the current if statement to branch here
when the flag is false,
and skip to `then` if the corresponding `if` was true.
+### `emit ( c -- )`
+print the single character c to output.
+
### `executable ( a u -- )`
marks the u bytes starting at address a as executable.
this is used primarily to mark the program break,
@@ -420,6 +423,11 @@ in a begin-while-repeat loop, loop back to the condition.
### `rot ( u1 u2 u3 -- u2 u3 u1 )`
rotate the top three values on the stack so that the third highest value is moved to the top.
+### `rp ( -- a )`
+yield the address of the return pointer.
+note that the address points to the return stack *before*
+this word was called.
+
### `s" ( "string" -- ) IMMEDIATE COMPILE-ONLY`
compile into the definition code to push the given string,
terminated by a double quote.
@@ -436,6 +444,11 @@ if -1 (true), the system is in compiling mode.
### `stderr ( -- 2 )`
push the file descriptor of stderr to the stack.
+### `sp ( -- a )`
+yield the address of the stack pointer.
+note that the address points to the stack *before*
+this value is pushed.
+
### `stdout ( -- 1 )`
push the file descriptor of stdout to the stack.