pub enum ParseCharRefError {
UnexpectedSign,
InvalidNumber(ParseIntError),
InvalidCodepoint(u32),
IllegalCharacter(u32),
}Expand description
Error while parsing a character reference (&#<dec-number>; or &#x<hex-number>;).
Variants§
UnexpectedSign
The number contains a sign character (+ or -), which is not allowed.
InvalidNumber(ParseIntError)
The number cannot be parsed due to non-numeric characters or numeric overflow.
InvalidCodepoint(u32)
The character reference does not represent a valid Unicode code point.
IllegalCharacter(u32)
The character reference expanded to a character not permitted in XML.
Currently only the 0x0 character produces this error.
Trait Implementations§
Source§impl Clone for ParseCharRefError
impl Clone for ParseCharRefError
Source§impl Debug for ParseCharRefError
impl Debug for ParseCharRefError
Source§impl Display for ParseCharRefError
impl Display for ParseCharRefError
Source§impl Error for ParseCharRefError
impl Error for ParseCharRefError
Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
Returns the lower-level source of this error, if any. Read more
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0:
use the Display impl or to_string()
Source§impl PartialEq for ParseCharRefError
impl PartialEq for ParseCharRefError
impl StructuralPartialEq for ParseCharRefError
Auto Trait Implementations§
impl Freeze for ParseCharRefError
impl RefUnwindSafe for ParseCharRefError
impl Send for ParseCharRefError
impl Sync for ParseCharRefError
impl Unpin for ParseCharRefError
impl UnsafeUnpin for ParseCharRefError
impl UnwindSafe for ParseCharRefError
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more