Skip to content

0.22.0 --- the null device at a position of a started program (KAL_SPAWN_NULL_IN, _OUT, _ERR) - #60

Merged
Sunrisepeak merged 2 commits into
mainfrom
openkal-0.22
Nov 2, 2026
Merged

Sunrisepeak merged 2 commits into
mainfrom
openkal-0.22

Conversation

@Sunrisepeak

Copy link
Copy Markdown
Member

openkal 0.22.0 --- the null device at a position

KAL_SPAWN_NULL_IN, KAL_SPAWN_NULL_OUT and KAL_SPAWN_NULL_ERR give a position of a started program the environment's null device: the program reads the end of input there and every write is accepted and discarded. KAL_PROCESS_PROP_NULL_STREAMS claims them; an implementation that does not claim them reports kal_err_not_supported, and a flag beside a non-zero stream at the same position is kal_err_invalid (clause 7.15, clause 11 entry 47).

Why: an ok image of clangd on Windows starts every module worker with standard input and output sent to /dev/null (LLVM's ExecuteNoWait); the image's preopens there are volumes, the C library finds no such name, and each start fails with ENOENT. The device is the environment's (/dev/null, NUL); a C library can serve a program's own reads and writes of it without the environment, but a started program needs a handle of the environment at the position, which a library could otherwise supply only as a channel drained by the caller for as long as the program runs.

  • No new name: kal_spawn's layout and SURFACE.txt are unchanged; a loader's binding table is unchanged.
  • Conformance: a copy given the device at its three positions reads the end of input and writes in full; a flag beside a stream is invalid; an implementation that does not claim the flags refuses them; the capability word holds no unassigned position.
  • Design record: .agents/docs/2026-11-03-openkal-0.22-design.md.

Implementations: openkal-linux 0.23.0, openkal-macos 0.20.0, openkal-windows 0.18.0, openkal-emscripten 0.11.0 (branches openkal-0.22).

…AWN_NULL_IN, _OUT, _ERR)

Co-authored-by: speak-agent <248744407+speak-agent@users.noreply.github.com>
…ding nothing of it (clause 7.13); a file keeps what is written

Co-authored-by: speak-agent <248744407+speak-agent@users.noreply.github.com>
@Sunrisepeak
Sunrisepeak merged commit ae400db into main Nov 2, 2026
23 of 24 checks passed
@Sunrisepeak
Sunrisepeak deleted the openkal-0.22 branch November 2, 2026 17:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant