Skip to main content

assert_invariants

Function assert_invariants 

Source
pub fn assert_invariants(cache: &Cache)
Expand description

Assert that the cache invariants are met:

  • current_size is the number of records
  • next_expiry of each partition is the min of its expiry times
  • access_priority has all the partitions in the correct order
  • expiry_priority has all the partitions in the correct order