D3216: py3: use pycompat.byterepr() instead of repr()

pulkit (Pulkit Goyal) phabricator at mercurial-scm.org
Wed Apr 11 08:31:57 EDT 2018


This revision was automatically updated to reflect the committed changes.
Closed by commit rHG58230f4fcc0b: py3: use pycompat.byterepr() instead of repr() (authored by pulkit, committed by ).

REPOSITORY
  rHG Mercurial

CHANGES SINCE LAST UPDATE
  https://phab.mercurial-scm.org/D3216?vs=7962&id=7968

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

AFFECTED FILES
  hgext/mq.py

CHANGE DETAILS

diff --git a/hgext/mq.py b/hgext/mq.py
--- a/hgext/mq.py
+++ b/hgext/mq.py
@@ -661,13 +661,13 @@
         exactneg = [g for g in patchguards
                     if g.startswith('-') and g[1:] in guards]
         if exactneg:
-            return False, repr(exactneg[0])
+            return False, pycompat.byterepr(exactneg[0])
         pos = [g for g in patchguards if g.startswith('+')]
         exactpos = [g for g in pos if g[1:] in guards]
         if pos:
             if exactpos:
-                return True, repr(exactpos[0])
-            return False, ' '.join(map(repr, pos))
+                return True, pycompat.byterepr(exactpos[0])
+            return False, ' '.join([pycompat.byterepr(p) for p in pos])
         return True, ''
 
     def explainpushable(self, idx, all_patches=False):



To: pulkit, #hg-reviewers, yuja
Cc: yuja, mercurial-devel


More information about the Mercurial-devel mailing list