const_oid/
error.rs

1//! Error types
2
3use core::fmt;
4
5/// Result type
6pub type Result<T> = core::result::Result<T, Error>;
7
8/// Error type
9#[derive(Copy, Clone, Debug, Eq, PartialEq)]
10pub struct Error;
11
12impl fmt::Display for Error {
13    fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
14        f.write_str("OID error")
15    }
16}
17
18#[cfg(feature = "std")]
19impl std::error::Error for Error {}