diff options
author | dan <[email protected]> | 2024-06-29 22:21:24 -0400 |
---|---|---|
committer | dan <[email protected]> | 2024-06-29 22:21:24 -0400 |
commit | 2e5554526b8e5efda19643369fe2c9768825cafd (patch) | |
tree | 2ae29693a038a8201c036780549db169d06fbe65 | |
parent | eb39d909fdf52b25a37a0e60e4185dc2881d3a2b (diff) | |
download | forth-master.tar.gz forth-master.tar.bz2 forth-master.zip |
-rw-r--r-- | readme.md | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -35,7 +35,7 @@ Current builtin operations: - `depth` - push that stack size - `clearstack` - clear the stack - `if <body> then ` - an optional section. `if` pops a val, and if that val is 0, skips to then. (Branch if zero) - - `: <name> <body> ;` - a procedure declaration. A new op is added, when it is run, the tokens in the body are evaluated. e.g. `: decr 1 - ; ` will define a new operation `incr`, that increments the valu at the top of the stack. + - `: <name> <body> ;` - a procedure declaration. A new op is added, when it is run, the tokens in the body are evaluated. e.g. `: incr 1 + ; ` will define a new operation `incr`, that increments the value at the top of the stack. - `nip` - discards the second val from the top - `tuck` - copies the top val and inserts it between the second and third - `incr` - increments the top value |