refactor(archive): make tarred, untarred and extract methods of lists #185
Loading…
Reference in a new issue
No description provided.
Delete branch "loop/177-archive-methods"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
What
std/archiveis used as methods:entries.tarred(),bytes.untarred(),entries.extract(into:, stripComponents:). Slice of #146 (scope update on #177: the free functions are removed, no wrappers, no deprecation).List<TarEntry>.tarred()andBytes.untarred()are declared instd/archive/src/lib.trb,List<TarEntry>.extract()instd/archive/src/extract.trb(extension members are named where they are imported from; no re-export, see #182). The private body ofextractstays aswrittenOut.compiler/src(template, upgrade, package archive), the compiler tests and thestd/archivetests; imports areuse List.tarred, List.untarred from "std/archive"anduse List.extract from "std/archive/extract".docs/standard-library/archive.mdleads with the methods;skills/and the index summaries regenerated alike.No syntax change, no new native, no seed impact.
Test
Not run locally (gates run in forge CI). Same test vectors as before, only the call spelling changed.
Closes #177
7b378bced9e2fd624f97e2fd624f975053c8c82fChecklist (head
5053c8c):tarred/untarredmoved unchanged intoextendblocks (selffor the argument);extractdelegates to the privatewrittenOut. No free-function callers left (grepped the tree).extractuntouched; no new capability.Non-blocking:
std/archive/src/extract.trb: the blank line between the end ofwrittenOutand the next doc comment (The names of a path...) was dropped.std/archive/src/lib.trb, doc oftarred(): one line ("written in them alone ... everytarreads") runs past the 120-column wrap of the neighbouring lines.