weak_table/
size_policy.rs

1/// No reason for this number as of now.
2pub const DEFAULT_INITIAL_CAPACITY: usize = 8;
3
4/// When the approximate load factor reaches `COLLECT_LOAD_FACTOR`, we remove
5/// all the expired pointers and then consider resizing.
6pub const COLLECT_LOAD_FACTOR: f32 = 0.9;
7
8/// If, after collection, the load factor is above `GROW_LOAD_FACTOR`, we grow.
9pub const GROW_LOAD_FACTOR: f32 = 0.75;
10
11/// If, after collection, the load factor is below `SHRINK_LOAD_FACTOR`, we shrink.
12pub const SHRINK_LOAD_FACTOR: f32 = 0.25;
13
14