Skip to content
Haoxi Zhan edited this page Dec 11, 2013 · 9 revisions

This page introduces instructions for :code and :exec.

Stack manipulations

Instruction Explanation input output

code_append

Append the first 2 items in :code

:code

:code

code_atom

If the first item in :code is a sequence → false, otherwise true

:code

:boolean

code_car

Perform first on the first item of :code

:code

:code

code_cdr

Perform rest on the first item of :code

:code

:code

code_cons

Concatenate the second item of :code into the first one

:code

:code

Execute codes

instruction explanation

code_do

execute the code (by pushing both it and code_popper to :exec)

code_do*

execute the code (by popping it and pushing to :exec)

code_do*range

While the counter moves from the second item of :integer to the first item of :integer by 1 (+ or -), keep executing the first item of :code

exec_do*range

similar to code_do*range but the source is from :exec

code_do*count

Execute the first item of :code for (the first item of :integer) times

exec_do*count

similar to code_do*count but the source if from :exec

code_do*times

exec_do*times

Clone this wiki locally