This library is in flux. APIs may change without notice. Generated from source with koruc 0.1.7 on 9/16/2026.
List.pop
~import std/list.popKoru Standard Library: the `pop` part of list.kz.
list.pop.kz · 2 tors
Koru Standard Library: the `pop` part of list.kz.
Joined via `~part pop` in list.kz; merged into the list module at load.
binding keeps <list!>), so it can be popped again or freed. `empty` when there
is nothing to pop. For scalar elements the popped value carries no obligation.
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.
List_i64 carries the label <list> with no obligation attached — a dimension, not a lifecycle.
// Koru Standard Library: the `pop` part of list.kz.
// Joined via `~part pop` in list.kz; merged into the list module at load.
//
// binding keeps <list!>), so it can be popped again or freed. `empty` when there
// is nothing to pop. For scalar elements the popped value carries no obligation.
~[comptime|transform] pub tor pop {
invocation: *const Invocation,
item: std/compiler:*const Item,
program: std/compiler:*const Program,
allocator: std.mem.Allocator
} -> SiteResult~pub tor pop-i64 { xs: *List_i64<list> }
| item i64
| empty