cli: add supplied-buffer decimal integer formatting to std
This commit is contained in:
30 files changed
+3609
-11
No files matched your search
@@ -230,3 +230,9 @@ Short destination capacity needs explicit failure without partial mutation. A su
|
||||
UTF-8 needs a scalar-level iteration contract without an owning iterator. Hex/Base64 decoders need a choice between permissive input and one reproducible accepted encoding, plus a defined destination state when a bad byte appears after a valid prefix. Size calculations must not trap before reporting short capacity.
|
||||
|
||||
**Resolved in STD-2a:** spec 16 §2.5–§2.7 define UTF-8 next/validate with explicit offsets, lowercase hex output with case-insensitive ASCII decoding, and canonical padded standard Base64 with checked unused bits. Decoders validate all input before checking output capacity and before writing; invalid input wins over short output and both preserve the entire destination. Capacity guards avoid arithmetic overflow. RFC 0019 records the policy. No streaming state, URL-safe/permissive options, borrowed iterator or allocation is introduced. Formatting remains STD-2b.
|
||||
|
||||
## Q-031 — Minimal formatting and signed limits
|
||||
|
||||
Formatting needs a defined byte representation, insufficient-capacity state and signed-minimum behavior before a library promises arbitrary integer output. A format-string parser or growable writer would add contracts beyond the supplied-buffer milestone.
|
||||
|
||||
**Resolved in the STD-2b branch:** spec 16 §2.8 defines decimal writers for u64/i64 and target-width usize/isize with one ordinary result enum. Complete capacity is checked before mutation, successful counts include the sign, suffixes stay unchanged and no terminator is emitted. Signed minimum is supported without negating it directly. RFC 0020 records the proposal. General formatting, other widths, floats and parsing remain separate work; explicit caller offsets compose records with existing byte copy.
|
||||
Reference in new issue
Block a user