changeset 43997:6e8678e7223a

revset: drop some unused code in the `remote` revset PyCharm flagged the `revs = [..]` as an unused assignment. But then neither `revs` nor `checkout` is used, and I can't see where `hg.addbranchrevs()` has external side effects. Differential Revision: https://phab.mercurial-scm.org/D7764
author Matt Harbison <matt_harbison@yahoo.com>
date Fri, 27 Dec 2019 19:00:38 -0500
parents 6dbb18e1ac8d
children 60de488cad11
files mercurial/revset.py
diffstat 1 files changed, 1 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/mercurial/revset.py	Fri Dec 27 18:52:48 2019 -0500
+++ b/mercurial/revset.py	Fri Dec 27 19:00:38 2019 -0500
@@ -2025,9 +2025,7 @@
         dest = getstring(l[1], _(b"remote requires a repository path"))
     dest = repo.ui.expandpath(dest or b'default')
     dest, branches = hg.parseurl(dest)
-    revs, checkout = hg.addbranchrevs(repo, repo, branches, [])
-    if revs:
-        revs = [repo.lookup(rev) for rev in revs]
+
     other = hg.peer(repo, {}, dest)
     n = other.lookup(q)
     if n in repo: