Copy keys when merging branches.

See #201.