tustvold commented on code in PR #4260:
URL: https://github.com/apache/arrow-rs/pull/4260#discussion_r1295724286


##########
arrow-flight/src/decode.rs:
##########
@@ -258,7 +259,7 @@ impl FlightDataDecoder {
                     ));
                 };
 
-                let buffer: arrow_buffer::Buffer = data.data_body.into();
+                let buffer = Buffer::from_bytes(data.data_body.into());

Review Comment:
   This API is kind of unfortunate, but I've not been able to find a good way 
to workaround the blanket From<AsRef<[u8]>> impl for Buffer



##########
arrow-flight/src/decode.rs:
##########
@@ -258,7 +259,7 @@ impl FlightDataDecoder {
                     ));
                 };
 
-                let buffer: arrow_buffer::Buffer = data.data_body.into();
+                let buffer = Buffer::from_bytes(data.data_body.into());

Review Comment:
   This API is kind of unfortunate, but I've not been able to find a good way 
to workaround the blanket `From<AsRef<[u8]>>` impl for Buffer



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to