pub fn decode_strict(
bytes: &[u8],
enc: DetectedEncoding,
) -> Result<Cow<'_, str>, ForgeError>Expand description
Strictly decode bytes according to a prior detect verdict.
BOMs are stripped before decoding. Any had_errors from encoding_rs
aborts with ForgeError::DecodeError — mojibake is never written.