Skip to content

Commit aea2f62

Browse files
committed
Remove incorrect debug_assert
1 parent ab3e4ea commit aea2f62

File tree

1 file changed

+2
-5
lines changed

1 file changed

+2
-5
lines changed

src/raw/mod.rs

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -118,11 +118,8 @@ fn special_is_empty(ctrl: u8) -> bool {
118118
#[inline]
119119
#[allow(clippy::cast_possible_truncation)]
120120
fn h1(hash: u64) -> usize {
121-
#[cfg(target_pointer_width = "32")]
122-
{
123-
debug_assert!(hash <= u64::from(u32::max_value()));
124-
}
125-
hash as usize // truncation
121+
// On 32-bit platforms we simply ignore the higher hash bits.
122+
hash as usize
126123
}
127124

128125
/// Secondary hash function, saved in the low 7 bits of the control byte.

0 commit comments

Comments
 (0)