use core::fmt::{Debug, Display};
/// Groups all possible crate errors
#[derive(Debug, PartialEq)]
pub enum Error {
/// It is not possible to insert an already existing element
AlreadyExistingElement(&'static str, &'static str),
/// Structure can't store more elements
InsufficientCapacity(&'static str, usize),
/// Index is out of structure bounds
OutOfBounds(&'static str, usize),
}
impl Display for Error {
#[inline]
fn fmt(&self, f: &mut core::fmt::Formatter<'_>) -> core::fmt::Result {
Debug::fmt(self, f)
}
}