stable-map 0.15.0

A hash map with temporarily stable indices
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
use {
    crate::StableMap,
    core::fmt::{Debug, Formatter},
};

impl<K, V, S> Debug for StableMap<K, V, S>
where
    K: Debug,
    V: Debug,
{
    fn fmt(&self, f: &mut Formatter<'_>) -> core::fmt::Result {
        let mut map = f.debug_map();
        for (k, v) in self {
            map.entry(k, v);
        }
        map.finish()
    }
}