diff options
Diffstat (limited to 'vendor/gix-object/src/traits.rs')
-rw-r--r-- | vendor/gix-object/src/traits.rs | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/vendor/gix-object/src/traits.rs b/vendor/gix-object/src/traits.rs index 193cd78c3..c0c4adee2 100644 --- a/vendor/gix-object/src/traits.rs +++ b/vendor/gix-object/src/traits.rs @@ -5,7 +5,7 @@ use crate::Kind; /// Writing of objects to a `Write` implementation pub trait WriteTo { /// Write a representation of this instance to `out`. - fn write_to(&self, out: impl std::io::Write) -> std::io::Result<()>; + fn write_to(&self, out: &mut dyn std::io::Write) -> std::io::Result<()>; /// Returns the type of this object. fn kind(&self) -> Kind; @@ -29,15 +29,15 @@ impl<T> WriteTo for &T where T: WriteTo, { - fn write_to(&self, out: impl Write) -> std::io::Result<()> { + fn write_to(&self, out: &mut dyn Write) -> std::io::Result<()> { <T as WriteTo>::write_to(self, out) } - fn size(&self) -> usize { - <T as WriteTo>::size(self) - } - fn kind(&self) -> Kind { <T as WriteTo>::kind(self) } + + fn size(&self) -> usize { + <T as WriteTo>::size(self) + } } |