Rename generic parameter and variable

Use W for Write
This commit is contained in:
yancy 2024-11-07 11:29:19 -06:00
parent 4797a75586
commit 3523b8e117
1 changed files with 3 additions and 3 deletions

View File

@ -8,12 +8,12 @@ macro_rules! impl_consensus_encoding {
($thing:ident, $($field:ident),+) => (
impl $crate::consensus::Encodable for $thing {
#[inline]
fn consensus_encode<R: $crate::io::Write + ?Sized>(
fn consensus_encode<W: $crate::io::Write + ?Sized>(
&self,
r: &mut R,
w: &mut W,
) -> core::result::Result<usize, $crate::io::Error> {
let mut len = 0;
$(len += self.$field.consensus_encode(r)?;)+
$(len += self.$field.consensus_encode(w)?;)+
Ok(len)
}
}