This library is in flux. APIs may change without notice. Generated from source with koruc 0.1.7 on 8/19/2026.

I/O

~import std/io

Koru Standard Library: I/O

io.kz · 17 tors · ~[comptime]· ~[runtime]

Koru Standard Library: I/O Basic input/output operations for Koru programs Finally! After achieving consciousness (metacircular compilation), we can now print "Hello, World!"

Phantom lifecycles

Derived from the phantom labels in the declarations below — state! issues an obligation the compiler will chase, !state discharges it, a bare state holds it without moving it. Nothing here is hand-drawn.

string 1 state allocated!

print

keywordcomptimetransform koru_std/io.kz:42

read-lines

aspirational koru_std/io.kz:140

read-stdin

<allocated!> koru_std/io.kz:176

read-file

<allocated!> koru_std/io.kz:200

free

<!allocated> koru_std/io.kz:229

print.ln

keywordcomptimetransform koru_std/io.kz:261

print.impl

norun koru_std/io.kz:270

eprint.ln

keywordcomptimetransform koru_std/io.kz:277

eprint

keywordcomptimetransform koru_std/io.kz:286

print.blk

comptimetransform koru_std/io.kz:1004

print.blk.impl

norun koru_std/io.kz:1013