868. relibc's seed comes under the unsafe gates
(The title and slug are provisional.)
calef ruled Q4 on #1896 (2026-10-10 UTC) as option G1. The C library's seed in vendor/relibc/
comes under the unsafe census and the unsafe fn contract check, in a lane of its own.
The debt
Milestone 835 (a C library, stage 1: files, clock and memory) seeded relibc's OS-neutral code into
vendor/relibc/. Every gate in script/lint and helpers/rust_source.py skips that directory as
somebody else's code. That was right for upstream's bytes. It is wrong for code nife now owns
(ยง265 (a C library started from relibc, whose Rust platform layer holds the capabilities)). About
580 seeded unsafe fns carry no # Safety section, and the unsafe census does not count the
seed's blocks.
What it builds
- The seed's
unsafe fns each gain a# Safetysection stating what the caller must hold. Most are C entry points whose contract is POSIX's ("sis a NUL-terminated string"), which is the text to write. - The
unsafe fncontract check and the unsafe census readvendor/relibc/(the exclusions inscript/lintandhelpers/rust_source.pynarrow fromvendortovendor/redoxfs), with the census's ceilings raised once, in the same commit, by the measured count and its reason. - The
vendor/README.mdexception is removed.
Reuse: the existing checks; nothing new is written. The # Safety sections are prose.
Done when
script/lint passes with vendor/relibc/ inside both checks, and vendor/README.md carries no
exception for it.
Index row
The C library's relibc seed under the unsafe census and the unsafe fn contract check: about 580
# Safety sections, and the exception milestone 835 recorded comes out.