You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
See #124 and #126, the name more(), is confusing as it indicate that we want to keep iterating over buckets/records whatever even if they all will be empty. Maybe rename to something like more_with_zero_count, or more_empty ? Though this does not convey that all the subsequent one will be empty.
The text was updated successfully, but these errors were encountered:
I'm also unsure if we can do it in a smooth backward compatible manner?
pub trait PickyIterator<T: Counter> {
...
// call more if defined (backward compatibility),
#[allow(deprecated)]
fn more_with_zero_count(&mut self, index_to_pick: usize) -> bool {
self.more(index_to_pick)
}
// provide a default impl for implementation that have already renamed more to
// more_with_zero_count.
#[deprecated(...)]
fn more(&mut self, index_to_pick: usize) -> bool {
self.more_with_zero_count(index_to_pick)
}
}
It's a bit dumb as the default impl obviously have infinite recursion, but this make it easy for any implementer of PickyIterator to be supported both with the old and the new name until the old name get removed.
Carreau
changed the title
rename more() to something more explicit.
[Breaking change] rename more() to something more explicit.
Aug 26, 2023
See #124 and #126, the name
more()
, is confusing as it indicate that we want to keep iterating over buckets/records whatever even if they all will be empty. Maybe rename to something likemore_with_zero_count
, ormore_empty
? Though this does not convey that all the subsequent one will be empty.The text was updated successfully, but these errors were encountered: