change: make Collections.merge more general