kalendarium 0.1.0

A library for converting Arabic numerals into Roman numerals and modern dates into the Kalendarium Romanum
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
use core::fmt;

/// Returned as an error if a numeral is constructed with an invalid input
#[derive(Debug, Clone, Copy, Eq, PartialEq)]
#[non_exhaustive]
pub struct OutOfRangeError;

impl fmt::Display for OutOfRangeError {
    fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
        write!(f, "Number out of range (must be between 1 and 9,999,999).")
    }
}