Skip to content
This repository has been archived by the owner on Feb 18, 2024. It is now read-only.

Commit

Permalink
Removed push_unchecked; removed length check from push
Browse files Browse the repository at this point in the history
  • Loading branch information
hohav committed Aug 17, 2022
1 parent 1b3ffc9 commit 095956a
Showing 1 changed file with 1 addition and 13 deletions.
14 changes: 1 addition & 13 deletions src/array/struct_/mutable.rs
Original file line number Diff line number Diff line change
Expand Up @@ -110,20 +110,8 @@ impl MutableStructArray {
}
}

/// Call this after pushing into each child array.
/// # Panics
/// This function panics if any of the children does not have exactly one more
/// element than before the last call of `push`.
/// Call this once for each "row" of children you push.
pub fn push(&mut self, valid: bool) {
self.push_unchecked(valid);
self.assert_lengths();
}

/// Call this after pushing into each child array.
/// # Safety
/// The caller must ensure that each of the children has exactly one more
/// element than before the last call of `push`.
pub fn push_unchecked(&mut self, valid: bool) {
match &mut self.validity {
Some(validity) => validity.push(valid),
None => match valid {
Expand Down

0 comments on commit 095956a

Please sign in to comment.