IsKey -> Semigroup
Mergeable dictionaries supporting O(log^2 n) amortized time merges, based on Red Black trees