Skip to content

Commit e6e5d5b

Browse files
committed
f - remove use of Into in ser_macros
1 parent 90b1006 commit e6e5d5b

File tree

2 files changed

+1
-4
lines changed

2 files changed

+1
-4
lines changed

lightning/src/util/ser.rs

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -422,9 +422,6 @@ macro_rules! impl_writeable_primitive {
422422
impl From<$val_type> for HighZeroBytesDroppedBigSize<$val_type> {
423423
fn from(val: $val_type) -> Self { Self(val) }
424424
}
425-
impl From<HighZeroBytesDroppedBigSize<$val_type>> for $val_type {
426-
fn from(val: HighZeroBytesDroppedBigSize<$val_type>) -> Self { val.0 }
427-
}
428425
}
429426
}
430427

lightning/src/util/ser_macros.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -187,7 +187,7 @@ macro_rules! decode_tlv {
187187
($reader: expr, $field: ident, (option, encoding: ($fieldty: ty, $encoding: ident))) => {{
188188
$field = {
189189
let field: $encoding<$fieldty> = ser::Readable::read(&mut $reader)?;
190-
Some(field.into())
190+
Some(field.0)
191191
};
192192
}};
193193
($reader: expr, $field: ident, (option, encoding: $fieldty: ty)) => {{

0 commit comments

Comments
 (0)