impl for borrowed types

This commit is contained in:
Rowan 2025-07-09 13:41:13 -04:00
parent 90cf6ef934
commit d1377270fb

View file

@ -7,6 +7,18 @@ macro_rules! impl_os_from_str {
f.write_str(&self.to_string())
}
}
impl $crate::OsDisplay for &$type {
fn fmt_os(&self, f: &mut OsStringFormatter) -> std::fmt::Result {
(**self).fmt_os(f)
}
}
impl $crate::OsDisplay for &mut $type {
fn fmt_os(&self, f: &mut OsStringFormatter) -> std::fmt::Result {
(**self).fmt_os(f)
}
}
};
}