impl Debug

This commit is contained in:
numzero 2025-11-02 02:12:15 +03:00
parent fc87672e10
commit f596505bd7

View File

@ -55,6 +55,12 @@ impl std::fmt::Binary for F8 {
} }
} }
impl std::fmt::Debug for F8 {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "{self:#b}f8")
}
}
impl From<u8> for F8 { impl From<u8> for F8 {
fn from(v: u8) -> Self { fn from(v: u8) -> Self {
if v == 0 { if v == 0 {