copies-rust: use the `entry` API for copy information too

Authored by marmoute.


copies-rust: use the entry API for copy information too

The code end up being complicated, but it split out the case were we add a new
entry from the case were we overwrite one. And that is the goal here, being able
to easily track value overwrite.

Differential Revision: https://phab.mercurial-scm.org/D9495