rust/hg-core/src/utils.rs
changeset 50412 331a3cbe1c9e
parent 50321 14b57943ae6d
child 51151 aba622c7dc7e
equal deleted inserted replaced
50411:071a6c1d291e 50412:331a3cbe1c9e
   299 
   299 
   300 /// Return the union of the two given maps,
   300 /// Return the union of the two given maps,
   301 /// calling `merge(key, left_value, right_value)` to resolve keys that exist in
   301 /// calling `merge(key, left_value, right_value)` to resolve keys that exist in
   302 /// both.
   302 /// both.
   303 ///
   303 ///
   304 /// CC https://github.com/bodil/im-rs/issues/166
   304 /// CC <https://github.com/bodil/im-rs/issues/166>
   305 pub(crate) fn ordmap_union_with_merge<K, V>(
   305 pub(crate) fn ordmap_union_with_merge<K, V>(
   306     left: OrdMap<K, V>,
   306     left: OrdMap<K, V>,
   307     right: OrdMap<K, V>,
   307     right: OrdMap<K, V>,
   308     mut merge: impl FnMut(&K, &V, &V) -> MergeResult<V>,
   308     mut merge: impl FnMut(&K, &V, &V) -> MergeResult<V>,
   309 ) -> OrdMap<K, V>
   309 ) -> OrdMap<K, V>