pub fn remove_slots_le(&self, max_root: Slot) -> Vec<(Slot, SlotCache)> {
        let mut removed_slots = vec![];
        self.cache.retain(|slot, slot_cache| {
            let should_remove = *slot <= max_root;
            if should_remove {
                removed_slots.push((*slot, slot_cache.clone()))
            }
            !should_remove
        });
        removed_slots
    }
// Removes slots less than or equal to `max_root`. Only safe to pass in a rooted slot,
// otherwise the slot removed could still be undergoing replay!
Removes slots less than or equal to `max_root`. Only safe to pass in a rooted slot,
otherwise the slot removed could still be undergoing replay!
Removes slots less than or equal to ` max_root ` . Only safe to pass in a rooted slot otherwise the slot removed could still be undergoing replay!
pub fn remove_slots_le(&self, max_root: Slot) -> Vec<(Slot, SlotCache)> {
        let mut removed_slots = vec![];
        self.cache.retain(|slot, slot_cache| {
            let should_remove = *slot <= max_root;
            if should_remove {
                removed_slots.push((*slot, slot_cache.clone()))
            }
            !should_remove
        });
        removed_slots
    }
pub fn remove_slots_le ( & self , max_root : Slot ) -> Vec < ( Slot , SlotCache ) > { let mut removed_slots = vec ! [ ] ; self . cache . retain ( | slot , slot_cache | { let should_remove = * slot <= max_root ; if should_remove { removed_slots . push ( ( * slot , slot_cache . clone ( ) ) ) } ! should_remove } ) ; removed_slots }
Removes slots less than or equal to `max_root`.
Removes slots less than or equal to ` max_root ` .
&self
max_root
Slot