use std::fmt;
#[derive(Debug)]
pub enum Error {
OutOfBounds
}
impl Error {
#[must_use]
pub const fn oob() -> Self {
Self::OutOfBounds
}
}
impl std::error::Error for Error {}
impl fmt::Display for Error {
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match self {
Self::OutOfBounds => write!(f, "Size if out of bounds")
}
}
}