Expand description
Byte-string escape decoder shared by the TOML config parser and the
--action CLI surface.
Accepts these escape forms (everything else is rejected with a typed error carrying a byte offset):
\r-> 0x0d\n-> 0x0a\t-> 0x09\0-> 0x00\\-> 0x5c (literal backslash)\xNN-> the byte with hex valueNN(two hex digits required)
Non-ASCII input bytes pass through verbatim — strings are walked at the
byte level (str::as_bytes()), so UTF-8-encoded characters land in the
output buffer unchanged.
No unsafe, no panic path on operator-supplied input: every error
variant carries the byte offset where the problem was detected so the
UI can underline the bad character.
Enums§
- Escape
Error - Errors produced by
decode_bytes_escape.
Functions§
- decode_
bytes_ escape - Decode a string containing escape sequences into a byte vector.