viirya commented on code in PR #3155:
URL: https://github.com/apache/arrow-rs/pull/3155#discussion_r1031305085


##########
arrow-array/src/builder/boolean_buffer_builder.rs:
##########
@@ -19,31 +19,36 @@ use arrow_buffer::{bit_util, Buffer, MutableBuffer};
 use arrow_data::bit_mask;
 use std::ops::Range;
 
+/// A builder for creating a boolean [`Buffer`]
 #[derive(Debug)]
 pub struct BooleanBufferBuilder {
     buffer: MutableBuffer,
     len: usize,
 }
 
 impl BooleanBufferBuilder {
+    /// Creates a new `BooleanBufferBuilder`
     #[inline]
     pub fn new(capacity: usize) -> Self {
         let byte_capacity = bit_util::ceil(capacity, 8);
         let buffer = MutableBuffer::new(byte_capacity);
         Self { buffer, len: 0 }
     }
 
+    /// Creates a new `BooleanBufferBuilder` from [`MutableBuffer`] of `len`
     pub fn new_from_buffer(buffer: MutableBuffer, len: usize) -> Self {
         assert!(len <= buffer.len() * 8);
         Self { buffer, len }
     }
 
     #[inline]
+    /// Returns the length of the buffer

Review Comment:
   I think we used to put doc on top of `#[inline]`.
   
   ```suggestion
       /// Returns the length of the buffer
       #[inline]
   ```



-- 
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