Patchwork D11653: chistedit: rename a confusingly named variable

login
register
mail settings
Submitter phabricator
Date Oct. 12, 2021, 9:31 p.m.
Message ID <differential-rev-PHID-DREV-osysocxyjjwecsuaf74c-req@mercurial-scm.org>
Download mbox | patch
Permalink /patch/49977/
State Superseded
Headers show

Comments

phabricator - Oct. 12, 2021, 9:31 p.m.
martinvonz created this revision.
Herald added a reviewer: durin42.
Herald added a reviewer: hg-reviewers.
Herald added a subscriber: mercurial-patches.

REVISION SUMMARY
  I would expect `ctxs` contain instances of some class from the
  `context` module but it actually contains instances of `histeditrule`.

REPOSITORY
  rHG Mercurial

BRANCH
  default

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

AFFECTED FILES
  hgext/histedit.py

CHANGE DETAILS




To: martinvonz, durin42, #hg-reviewers
Cc: mercurial-patches, mercurial-devel

Patch

diff --git a/hgext/histedit.py b/hgext/histedit.py
--- a/hgext/histedit.py
+++ b/hgext/histedit.py
@@ -1716,11 +1716,11 @@ 
                 _(b'%s is not an ancestor of working directory') % short(root)
             )
 
-        ctxs = []
+        rules = []
         for i, r in enumerate(revs):
-            ctxs.append(histeditrule(ui, repo[r], i))
+            rules.append(histeditrule(ui, repo[r], i))
         with util.with_lc_ctype():
-            rc = curses.wrapper(functools.partial(_chisteditmain, repo, ctxs))
+            rc = curses.wrapper(functools.partial(_chisteditmain, repo, rules))
         curses.echo()
         curses.endwin()
         if rc is False: