From b8b51c516f2ffc61349ee4fa0009203338e1a368 Mon Sep 17 00:00:00 2001 From: Geoffry Song Date: Wed, 20 Nov 2024 16:30:23 -0800 Subject: [PATCH] Fix warning about Cursor::split() (#176) Fixes a breakage from recent nightly --- pb-jelly/src/extensions.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pb-jelly/src/extensions.rs b/pb-jelly/src/extensions.rs index be8f425..9385e75 100644 --- a/pb-jelly/src/extensions.rs +++ b/pb-jelly/src/extensions.rs @@ -144,7 +144,7 @@ impl Extension for RepeatedExtension { let mut msg = U::default(); if wire_format == wire_format::Type::LengthDelimited { let length = varint::read(&mut buf)?.expect("corrupted Unrecognized"); - msg.deserialize(&mut buf.split(length as usize))?; + msg.deserialize(&mut PbBufferReader::split(&mut buf, length as usize))?; } else { // we rely on the fact that the appropriate `Message` impls for i32/Fixed32/etc. only read the prefix of // `buf`. this is a little dirty