Skip to content

Commit

Permalink
Added subset tests and fixed bugs
Browse files Browse the repository at this point in the history
  • Loading branch information
BGluth committed Mar 22, 2023
1 parent ff81d71 commit bc45238
Show file tree
Hide file tree
Showing 3 changed files with 312 additions and 28 deletions.
6 changes: 3 additions & 3 deletions src/nibbles.rs
Original file line number Diff line number Diff line change
Expand Up @@ -312,7 +312,7 @@ impl Nibbles {
r
}

/// Appends a nibble to the front.
/// Pushes a nibble to the front.
///
/// # Panics
/// Panics if appending the `Nibble` causes an overflow (total nibbles >
Expand All @@ -326,7 +326,7 @@ impl Nibbles {
self.packed |= U256::from(n) << shift_amt;
}

/// Appends a nibble to the back.
/// Pushes a nibble to the back.
///
/// # Panics
/// Panics if appending the `Nibble` causes an overflow (total nibbles >
Expand All @@ -343,7 +343,7 @@ impl Nibbles {
/// # Panics
/// Panics if appending the `Nibble` causes an overflow (total nibbles >
/// 64).
pub fn push_nibbles(&mut self, n: &Self) {
pub fn push_nibbles_front(&mut self, n: &Self) {
let new_count = self.count + n.count;
assert!(new_count <= 64);

Expand Down
Loading

0 comments on commit bc45238

Please sign in to comment.