@@ -1160,7 +1160,7 @@ impl<'a, 'c: 'a> TypeResolver<'a, 'c> {
11601160 |"lightning::sign::KeyMaterial" |"lightning::chain::ClaimId"
11611161 if !is_ref => Some ( "crate::c_types::ThirtyTwoBytes" ) ,
11621162
1163- "lightning::io::Read" => Some ( "crate::c_types::u8slice" ) ,
1163+ "lightning::util::ser::LengthLimitedRead" | "lightning:: io::Read" => Some ( "crate::c_types::u8slice" ) ,
11641164
11651165 _ => None ,
11661166 }
@@ -1287,7 +1287,7 @@ impl<'a, 'c: 'a> TypeResolver<'a, 'c> {
12871287 "lightning::chain::ClaimId" if is_ref=> Some ( "&::lightning::chain::ClaimId( unsafe { *" ) ,
12881288
12891289 // List of traits we map (possibly during processing of other files):
1290- "lightning::io::Read" => Some ( "&mut " ) ,
1290+ "lightning::util::ser::LengthLimitedRead" | "lightning:: io::Read" => Some ( "&mut " ) ,
12911291
12921292 _ => None ,
12931293 } . map ( |s| s. to_owned ( ) )
@@ -1399,7 +1399,7 @@ impl<'a, 'c: 'a> TypeResolver<'a, 'c> {
13991399 if is_ref => Some ( " })" ) ,
14001400
14011401 // List of traits we map (possibly during processing of other files):
1402- "lightning::io::Read" => Some ( ".to_reader ()" ) ,
1402+ "lightning::util::ser::LengthLimitedRead" | "lightning:: io::Read" => Some ( ".to_slice ()" ) ,
14031403
14041404 _ => None ,
14051405 } . map ( |s| s. to_owned ( ) )
@@ -1530,7 +1530,7 @@ impl<'a, 'c: 'a> TypeResolver<'a, 'c> {
15301530 |"lightning::sign::KeyMaterial" |"lightning::chain::ClaimId"
15311531 if !is_ref => Some ( "crate::c_types::ThirtyTwoBytes { data: " ) ,
15321532
1533- "lightning::io::Read" => Some ( "crate::c_types::u8slice::from_vec(&crate::c_types::reader_to_vec(" ) ,
1533+ "lightning::util::ser::LengthLimitedRead" | "lightning:: io::Read" => Some ( "crate::c_types::u8slice::from_vec(&crate::c_types::reader_to_vec(" ) ,
15341534
15351535 _ => None ,
15361536 } . map ( |s| s. to_owned ( ) )
@@ -1640,7 +1640,7 @@ impl<'a, 'c: 'a> TypeResolver<'a, 'c> {
16401640 |"lightning::sign::KeyMaterial" |"lightning::chain::ClaimId"
16411641 if !is_ref => Some ( ".0 }" ) ,
16421642
1643- "lightning::io::Read" => Some ( "))" ) ,
1643+ "lightning::util::ser::LengthLimitedRead" | "lightning:: io::Read" => Some ( "))" ) ,
16441644
16451645 _ => None ,
16461646 } . map ( |s| s. to_owned ( ) )
@@ -1661,7 +1661,7 @@ impl<'a, 'c: 'a> TypeResolver<'a, 'c> {
16611661 /// TODO: We should never need to use this!
16621662 fn real_rust_type_mapping < ' equiv > ( & self , thing : & ' equiv str ) -> & ' equiv str {
16631663 match thing {
1664- "lightning::io::Read" => "crate::c_types::io::Read" ,
1664+ "lightning::util::ser::LengthLimitedRead" | "lightning:: io::Read" => "crate::c_types::io::Read" ,
16651665 _ => thing,
16661666 }
16671667 }
0 commit comments