pub fn append(&mut self, other: &mut Self)
    where
        K: Ord,
    {
        // Do we have to append anything at all?
        if other.is_empty() {
            return;
        }

        // We can just swap `self` and `other` if `self` is empty.
        if self.is_empty() {
            mem::swap(self, other);
            return;
        }

        let self_iter = mem::take(self).into_iter();
        let other_iter = mem::take(other).into_iter();
        let root = BTreeMap::ensure_is_owned(&mut self.root);
        root.append_from_sorted_iters(self_iter, other_iter, &mut self.length)
    }
Constructs a mutable double-ended iterator over a sub-range of elements in the map.
The simplest way is to use the range syntax `min..max`, thus `range(min..max)` will
yield elements from min (inclusive) to max (exclusive).
The range may also be entered as `(Bound<T>, Bound<T>)`, so for example
`range((Excluded(4), Included(10)))` will yield a left-exclusive, right-inclusive
range from 4 to 10.

# Panics

Panics if range `start > end`.
Panics if range `start == end` and both bounds are `Excluded`.

# Examples

Basic usage:

```
use std::collections::BTreeMap;

let mut map: BTreeMap<&str
benchmarks/haystacks/code/rust-library.rs