Skip to content

Commit

Permalink
fix: Address overflow combining u64 hashes in Debug builds (#16323)
Browse files Browse the repository at this point in the history
  • Loading branch information
alexander-beedie authored May 20, 2024
1 parent 18c5601 commit 129c951
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion crates/polars-core/src/series/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -147,7 +147,7 @@ impl Hash for Wrap<Series> {
let rs = RandomState::with_seeds(0, 0, 0, 0);
let mut h = vec![];
self.0.vec_hash(rs, &mut h).unwrap();
let h = UInt64Chunked::from_vec("", h).sum();
let h = h.into_iter().fold(0, |a: u64, b| a.wrapping_add(b));
h.hash(state)
}
}
Expand Down

0 comments on commit 129c951

Please sign in to comment.