diff --git a/src/lazy/binary/raw/v1_1/value.rs b/src/lazy/binary/raw/v1_1/value.rs index 9b74b09f..d1b87e63 100644 --- a/src/lazy/binary/raw/v1_1/value.rs +++ b/src/lazy/binary/raw/v1_1/value.rs @@ -241,15 +241,15 @@ impl<'top> LazyRawBinaryValue_1_1<'top> { let value = match self.encoded_value.value_body_length { 8 => { let mut buffer = [0; 8]; - let val_bytes = self.input.slice(1, 8); - buffer[..8].copy_from_slice(val_bytes.bytes()); + let val_bytes = self.input.bytes_range(1, 8); + buffer[..8].copy_from_slice(val_bytes); f64::from_le_bytes(buffer) } 4 => { let mut buffer = [0; 4]; - let val_bytes = self.input.slice(1, 4); - buffer[..4].copy_from_slice(val_bytes.bytes()); + let val_bytes = self.input.bytes_range(1, 4); + buffer[..4].copy_from_slice(val_bytes); f32::from_le_bytes(buffer).into() }