D7070: copies: extract data extraction into a `revinfo` function

martinvonz (Martin von Zweigbergk) phabricator at mercurial-scm.org
Wed Oct 16 12:30:42 EDT 2019


martinvonz added a comment.


  To clarify, you don't see any slowdown if you apply the following patch?
  
  diff --git a/mercurial/copies.py b/mercurial/copies.py
  
  - a/mercurial/copies.py
  
  +++ b/mercurial/copies.py
  @@ -192,7 +192,7 @@ def _revinfogetter(repo):
  
    def revinfo(rev):
        p1, p2 = cl.parentrevs(rev)
        ctx = repo[rev]
  
  - p1copies, p2copies = ctx._copies
  
  +        p1copies, p2copies = ctx.p1copies(), ctx.p2copies()
  
    removed = ctx.filesremoved()
    return p1, p2, p1copies, p2copies, removed

REPOSITORY
  rHG Mercurial

CHANGES SINCE LAST ACTION
  https://phab.mercurial-scm.org/D7070/new/

REVISION DETAIL
  https://phab.mercurial-scm.org/D7070

To: marmoute, #hg-reviewers
Cc: martinvonz, mercurial-devel


More information about the Mercurial-devel mailing list