Mercurial > public > mercurial-scm > hg
comparison mercurial/subrepo.py @ 44823:3b7aabd02e11
cleanup: avoid extra node/ctx conversions in logcmdutil.diffordiffstat
I'm about to write some code that wants to pass a memctx to
diffordiffstat, but this feels like a meritorious cleanup anyway,
since the first thing this method does is turn nodes into contexts,
and most callers have a context handy.
Differential Revision: https://phab.mercurial-scm.org/D8502
author | Augie Fackler <augie@google.com> |
---|---|
date | Thu, 07 May 2020 16:54:17 -0400 |
parents | 2f290136b7d6 |
children | a56ba57c837d |
comparison
equal
deleted
inserted
replaced
44822:118f067f6bd1 | 44823:3b7aabd02e11 |
---|---|
615 node2 = node.bin(node2) | 615 node2 = node.bin(node2) |
616 logcmdutil.diffordiffstat( | 616 logcmdutil.diffordiffstat( |
617 ui, | 617 ui, |
618 self._repo, | 618 self._repo, |
619 diffopts, | 619 diffopts, |
620 node1, | 620 self._repo[node1], |
621 node2, | 621 self._repo[node2], |
622 match, | 622 match, |
623 prefix=prefix, | 623 prefix=prefix, |
624 listsubrepos=True, | 624 listsubrepos=True, |
625 **opts | 625 **opts |
626 ) | 626 ) |