improve readme

master
Ondřej Hruška 4 years ago
parent 77efa0fdc0
commit d6fc82c533
Signed by untrusted user: MightyPork
GPG Key ID: 2C5FD5035250423D
  1. 9
      README.md

@ -188,6 +188,7 @@ The different ways to specify a value can be grouped as "reads" and "writes":
Objects (`@reg`, `@sym`) can be read or written as if they were a register, but only if the referenced object supports it.
Other objects may produce a runtime fault or set the INVALID flag.
The object syntax is also used to read values yielded by a generator-like coroutine.
In the instruction lists below, I will use the symbols `Rd` for reads, `Wr` for writes, `RW` for read-writes, and `@Obj` for object handles,
with optional description after an apostrophe, such as: `(add Wr'dst Rd'a Rd'b)`.
@ -473,9 +474,15 @@ Jumping to a label is always safer than a manual skip.
; The arguments are passed as argX. Return values are stored in resX registers.
(call PROC Rd...)
; Exit the current routine with return values
; Spawn a coroutine. The handle is stored in the output register.
(spawn Wr'handle PROC Rd...)
; Exit the current routine (or coroutine) with return values
(ret Rd...)
; Wait for a coroutine to complete, read its return values and delete it.
(join @Obj)
; Generate a run-time fault with a debugger message
(fault)
(fault message)

Loading…
Cancel
Save