use std::fmt::Display;
#[derive(Debug)]
#[cfg_attr(feature = "eq", derive(PartialEq, Eq))]
pub enum InternalError {
UnsanitisedCharInString(char),
IncorrectChunkLineNumber { expected: u32, got: u32 },
ParagraphBreakTooShort,
ParagraghBreakNonwhitespace,
BeginCommand,
EndCommand,
UnbrokenParagraph,
}
impl Display for InternalError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
f.write_fmt(format_args!("{self:?}"))
}
}
impl std::error::Error for InternalError {}