rebase: always pass destination as revnum to _handleskippingobsolete()
We were passing it as a revision number in one place and as a context
in another. It worked because the only use was in "repo[dest].rev()",
but it was confusing. By always passing a revision number, we can also
remove that unnecessary lookup.
--- a/hgext/rebase.py Thu Jun 29 23:04:47 2017 -0700
+++ b/hgext/rebase.py Wed Jun 28 14:53:54 2017 -0700
@@ -317,7 +317,7 @@
hint=_('use --keep to keep original changesets'))
obsrevs = _filterobsoleterevs(self.repo, set(rebaseset))
- self._handleskippingobsolete(rebaseset, obsrevs, dest)
+ self._handleskippingobsolete(rebaseset, obsrevs, dest.rev())
result = buildstate(self.repo, dest, rebaseset, self.collapsef,
self.obsoletenotrebased)
@@ -1464,7 +1464,7 @@
if allsuccessors:
# Look for successors of obsolete nodes to be rebased among
# the ancestors of dest
- ancs = cl.ancestors([repo[dest].rev()],
+ ancs = cl.ancestors([dest],
stoprev=min(allsuccessors),
inclusive=True)
for s in allsuccessors: