Mercurial > hg
changeset 44179:293cab97a766
merge: replace a repo.lookup('.') by more typical repo['.'].node()
The `repo.lookup('.')` form comes from b3311e26f94f (merge: fix
--preview to show all nodes that will be merged (issue2043).,
2010-02-15). I don't know why that commit changed from `repo['.']`,
but I don't think there's any reason to do that. Note that performance
should not be a reason (anymore?), because repo.lookup() is
implemented by first creating a context object.
Differential Revision: https://phab.mercurial-scm.org/D7998
author | Martin von Zweigbergk <martinvonz@google.com> |
---|---|
date | Fri, 24 Jan 2020 15:18:19 -0800 |
parents | bd4f666b55a7 |
children | d84420232492 |
files | mercurial/commands.py |
diffstat | 1 files changed, 1 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/mercurial/commands.py Fri Jan 24 16:07:42 2020 -0800 +++ b/mercurial/commands.py Fri Jan 24 15:18:19 2020 -0800 @@ -4881,7 +4881,7 @@ if opts.get(b'preview'): # find nodes that are ancestors of p2 but not of p1 - p1 = repo.lookup(b'.') + p1 = repo[b'.'].node() p2 = node nodes = repo.changelog.findmissing(common=[p1], heads=[p2])