Seems range inclusive doesn't optimise very well...

This commit is contained in:
Gwilym Kuiper 2022-03-21 23:16:02 +00:00
parent 451868723f
commit 1c33c8544e

View file

@ -657,7 +657,7 @@ impl<K, V> NodeStorage<K, V> {
where
K: Eq,
{
for distance_to_initial_bucket in 0..=self.max_distance_to_initial_bucket {
for distance_to_initial_bucket in 0..(self.max_distance_to_initial_bucket + 1) {
let location = fast_mod(
self.nodes.len(),
hash + distance_to_initial_bucket as HashType,