1
0
Fork 0
forked from wry/wry

config: add create-mark, jump-to-mark, and copy-mark actions

This commit is contained in:
Julian Orth 2025-07-20 15:44:50 +02:00
parent e30e2595a1
commit eb625b34cc
19 changed files with 1193 additions and 9 deletions

View file

@ -198,6 +198,15 @@ impl<K: Eq, V, const N: usize> SmallMapMut<K, V, N> {
None
}
pub fn get_mut(&mut self, k: &K) -> Option<&mut V> {
for (ek, ev) in &mut self.m {
if ek == k {
return Some(ev);
}
}
None
}
pub fn get_or_default_mut(&mut self, k: K) -> &mut V
where
V: Default,