mergestate: replace addmergedother() with generic addcommitinfo() (API)
Storing that a file is resolved for the other parent while merging is just one
case of things we will like to store in the mergestate. There are more which we
will like to store.
This patch replaces addmergedother() with a much more generic
addcommitinfo(). Doing this, we also blinding stores the same key value pair
generated by the merge code instead of touching them.
Differential Revision: https://phab.mercurial-scm.org/D8923