#[derive(Debug, PartialEq, Eq, thiserror::Error)]
pub enum HlcError {
#[error("Out of range timestamp")]
OutOfRangeTimestamp,
#[error("Drift exeeded the maximum allowed: {0} > {1}")]
DriftTooLarge(usize, usize),
#[error("Physical time exceeds maximum value: {0} > {1}")]
PhysicalTimeExceedsMax(i64, u64),
#[error("Logical clock exceeds maximum value: {0} > {1}")]
LogicalClockExceedsMax(u64, u64),
#[error("Timestamp is below the minimum value: {0} < {1}")]
TimestampBelowMin(i64, i64),
}
pub type HlcResult<T> = Result<T, HlcError>;