Available on crate feature
strict-compat only.Expand description
Hand-rolled Strict-mode argv parser (AD-007). Public so the
rusty-figlet binary can dispatch to its byte-equal upstream
diagnostics; the SemVer policy on this module’s surface matches the
rest of the public library API per FR-050. Gated by the
strict-compat leaf (v0.2+).
Hand-rolled Strict-mode argv parser per AD-007.
Mirrors upstream figlet(6) getopt diagnostics byte-for-byte (modulo
the figlet: → rusty-figlet: program-name substitution applied by
the test harness): excluded short flags surface
figlet: invalid option -- '<char>'; excluded long flags surface
figlet: unrecognized option '<flag>'.
Last-wins semantics for repeated flags (-c/-l/-r, layout flags,
-w) per FR-022 + FR-023.
Structs§
- Strict
Args - Outcome of
parse_argvon success — the resolved argument bag.
Enums§
- Justify
Kind - Resolved justify-class flag for Strict mode.
- Layout
Kind - Resolved layout-class flag for Strict mode.
- Strict
Error - Strict-mode parse error. Carries the formatted, byte-equal upstream diagnostic for emission on stderr.
Functions§
- format_
unknown_ flag - Format an unknown-flag diagnostic per FR-042 / FR-043.
- parse_
argv - Parse
argv(NOT includingargv[0]) into aStrictArgs. Stops at the first excluded/unknown flag and returnsStrictErrorwith the upstream-format diagnostic.