use std::error::Error;
use std::fmt::{Display, Formatter};
pub use cell::MeshCell;
pub(crate) use code::MeshCode;
pub use coord::MeshCoord;
pub use node::MeshNode;
pub use unit::MeshUnit;
mod cell;
mod code;
mod coord;
mod node;
mod unit;
#[inline]
#[must_use]
pub const fn is_meshcode(meshcode: &u32) -> bool {
MeshNode::try_from_meshcode(meshcode).is_some()
}
#[derive(Debug, PartialEq, Eq)]
pub struct MeshTryFromError;
impl MeshTryFromError {
#[cold]
const fn new() -> Self {
Self {}
}
}
impl Error for MeshTryFromError {}
impl Display for MeshTryFromError {
fn fmt(&self, f: &mut Formatter) -> std::fmt::Result {
f.write_str("the value would be out-of-bounds of the output")
}
}