File tree Expand file tree Collapse file tree 3 files changed +4
-4
lines changed
src/common/arrow/src/arrow Expand file tree Collapse file tree 3 files changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -320,7 +320,7 @@ impl<T: NativeType> MutablePrimitiveArray<T> {
320
320
/// Note that if it is the first time a null appears in this array,
321
321
/// this initializes the validity bitmap (`O(N)`).
322
322
/// # Panic
323
- /// Panics iff index is larger than `self.len()`.
323
+ /// Panics iff index is larger than or equal to `self.len()`.
324
324
pub fn set ( & mut self , index : usize , value : Option < T > ) {
325
325
assert ! ( index < self . len( ) ) ;
326
326
// Safety:
Original file line number Diff line number Diff line change @@ -89,7 +89,7 @@ impl UnionArray {
89
89
. try_for_each ( |( index, ( data_type, child) ) | {
90
90
if data_type != child {
91
91
Err ( Error :: oos ( format ! (
92
- "The children DataTypes of a UnionArray must equal the children data types.
92
+ "The children DataTypes of a UnionArray must equal the children data types.
93
93
However, the field {index} has data type {data_type:?} but the value has data type {child:?}"
94
94
) ) )
95
95
} else {
@@ -244,7 +244,7 @@ impl UnionArray {
244
244
/// # Implementation
245
245
/// This operation is `O(F)` where `F` is the number of fields.
246
246
/// # Panic
247
- /// This function panics iff `offset + length >= self.len()`.
247
+ /// This function panics iff `offset + length > self.len()`.
248
248
#[ inline]
249
249
pub fn slice ( & mut self , offset : usize , length : usize ) {
250
250
assert ! (
Original file line number Diff line number Diff line change @@ -162,7 +162,7 @@ impl<T> Buffer<T> {
162
162
163
163
/// Slices this buffer starting at `offset`.
164
164
/// # Panics
165
- /// Panics iff `offset` is larger than `len`.
165
+ /// Panics iff `offset + length ` is larger than `len`.
166
166
#[ inline]
167
167
pub fn slice ( & mut self , offset : usize , length : usize ) {
168
168
assert ! (
You can’t perform that action at this time.
0 commit comments