[Updated] D8886: mergeresult: introduce getfile() and use it where required
indygreg (Gregory Szorc)
phabricator at mercurial-scm.org
Sat Aug 8 16:30:06 UTC 2020
This revision is now accepted and ready to land.
indygreg added inline comments.
indygreg accepted this revision.
INLINE COMMENTS
> merge.py:622
> + return self._filemapping[filename]
> + return default_return
> +
This pattern is better expressed as `self._filemapping.get(filename, default_return)` since it avoids an extra lookup.
Please submit a follow-up if you think this code is performance sensitive.
REPOSITORY
rHG Mercurial
BRANCH
default
CHANGES SINCE LAST ACTION
https://phab.mercurial-scm.org/D8886/new/
REVISION DETAIL
https://phab.mercurial-scm.org/D8886
To: pulkit, #hg-reviewers, indygreg
Cc: indygreg, mercurial-patches
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mercurial-scm.org/pipermail/mercurial-patches/attachments/20200808/4f44e5f2/attachment-0002.html>
More information about the Mercurial-patches
mailing list