Skip to content

AlxLib 1.3.1

Choose a tag to compare

@AlexisVon AlexisVon released this 17 Oct 06:04
· 17 commits to main since this release

Minor release — the yield service, plus the 1.3.1 patch. Hosts linking the shared libraries must relink: the SONAME moves to .so.1.3.

The yield point (1.3.0): yield(time_ms = 0, maxcnt = 0) joins the language — the one script-written service point, where the engine takes calls delivered from other threads. engine::yield queues a call to a def by name (late binding), fwrap::currying mints a caller-owned delivery handle for a link's communication threads, and set_max_yield / engine_config::max_yield bound the queue (default 256, 0 = unlimited). A serviced call runs under root pose — it sees the root variables, not the main walk's locals — through the same entry ladder call() uses, and every outcome travels inside its future (value, script error, no main fiber, yield full, expired, not executed, InterruptedError); a future is never broken. A nested yield() raises a script-level YieldError("nested yield") that the serviced call may catch; a yield during module init is a script-level error. A 50 ms background pass (the script layer's first thread) liquidates expired deliveries, and its on_csys entries are the only ones emitted off an engine's own thread. error_type gains YieldError, O_YIELD appends after O_DEBUG (no renumbering), and result moves to the script namespace with engine::result kept as an alias.

A failed run no longer resets (1.3.0): an execution-time failure only ends that run — root variables, defs and loaded modules survive; reset() is the only reaper. This is what lets a serviced call fail without taking the host's state with it.

1.3.1: import/link stop swallowing ResourceError / MemoryError / NativeError from a module init or a link's load/create entry — the failure now reaches an enclosing script try or the entry's ladder, and a throwing load/create surfaces as NativeError instead of a silent success. The yield queue's internals settle their names, and a documentation audit round corrects the reference where it described behaviour the engine does not have. No opcode or AST change; old .axp products run unchanged.

Version / SONAME: the library steps 1.2.2 → 1.3.0 → 1.3.1. The minor bump moves the SONAME to .so.1.3; 1.3.1 is a patch and keeps it.