lib: banner purge + WHY-only comment sweep (rule 8)

Every // ---- section banner dies (132 -> 0): names carry the WHAT.
Narration deleted (filename restatements, run-with lines, what-the-
next-line-does); every ref/hare cite, task cite, divergence, ABI/
layout contract, and ownership qualifier kept (borrowed-view lines
restored where the sweep over-cut). Comment-only proven: all 442
walk-workdir .s and 32 import-probe .s byte-identical before/after;
libbyteid 56-roster all-ID.
This commit is contained in:
2026-08-08 21:10:18 +09:00
parent 659e859f34
commit aadc6618f0
90 changed files with 259 additions and 919 deletions

View File

@@ -1,8 +1,6 @@
// hextest — exercises lib/encoding/hex's io-streaming surface. Run with
// `out/bin/ww run lib/encoding/hex/hextest.ww`. Mirrors Hare's hex
// @test fns (ref/hare/encoding/hex/hex.ha:82,96,194) plus a full-byte
// round-trip. A failing row aborts via the assert/abort builtin (task #5
// @test conversion).
// Mirrors Hare's hex @test fns (ref/hare/encoding/hex/hex.ha:82,96,194)
// plus a full-byte round-trip. A failing row aborts via the assert/abort
// builtin (task #5 @test conversion).
//
// The streaming decoder (newdecoder) is deferred (#247), so the decode
// side is exercised through decodestr only.
@@ -33,8 +31,6 @@ fn cafebabe() [8]u8 = {
return r;
};
// ---- encodestr ---- ref/hare/encoding/hex/hex.ha:82
@test fn encodestr_basic() void = {
let in: [8]u8 = cafebabe();
assert(!(!streq(hex.encodestr(in[0:8]), "cafebabedeadf00d")));
@@ -57,8 +53,6 @@ fn cafebabe() [8]u8 = {
assert(!(hex.encodestr(in[0:0]).len != 0));
};
// ---- encode (io.handle sink) ---- ref/hare/encoding/hex/hex.ha:96
@test fn encode_stream() void = {
let in: [8]u8 = cafebabe();
let out: memio.stream = memio.dynamic();
@@ -69,8 +63,6 @@ fn cafebabe() [8]u8 = {
assert(!(!streq(memio.string(&out), "cafebabedeadf00d")));
};
// ---- decodestr round-trip ---- ref/hare/encoding/hex/hex.ha:194
@test fn decodestr_lower() void = {
match (hex.decodestr("cafebabedeadf00d")) {
case let b: []u8 => {
@@ -110,9 +102,8 @@ fn cafebabe() [8]u8 = {
};
};
// ---- decodestr error cases ---- ref/hare/encoding/hex/hex.ha:154,199
//
// Odd length and non-hex chars both return errors.invalid.
// Odd length and non-hex chars both return errors.invalid
// (ref/hare/encoding/hex/hex.ha:154,199).
@test fn decodestr_odd() void = {
match (hex.decodestr("abc")) {
@@ -135,8 +126,6 @@ fn cafebabe() [8]u8 = {
};
};
// ---- round-trip every byte value 0..255 --------------------------------
@test fn roundtrip_all_bytes() void = {
let src: [256]u8;
let i: i32 = 0;