We likely take ownership of the input to PointerBuf::parse but do not include it in resulting ParseError.
PointerBuf::parse:
pub fn parse(s: impl Into<String>) -> Result<Self, ParseError> {
let s = s.into();
validate(&s)?;
Ok(Self(s))
}
ParseError:
pub enum ParseError {
NoLeadingBackslash,
InvalidEncoding {
offset: usize,
source: InvalidEncodingError,
},
}