tustvold commented on code in PR #3793:
URL: https://github.com/apache/arrow-rs/pull/3793#discussion_r1123435336
##########
arrow-array/src/array/fixed_size_binary_array.rs:
##########
@@ -234,8 +242,10 @@ impl FixedSizeBinaryArray {
{
let mut len = 0;
let mut byte = 0;
- let mut null_buf = MutableBuffer::from_len_zeroed(0);
- let mut buffer = MutableBuffer::from_len_zeroed(0);
+
+ let iter_size_hint = iter.size_hint().0;
+ let mut null_buf = MutableBuffer::from_len_zeroed((iter_size_hint + 7)
/ 8);
Review Comment:
I would perhaps expect to see `MutableBuffer::new` here -
https://docs.rs/arrow-buffer/latest/arrow_buffer/struct.MutableBuffer.html#method.new?
--
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]