mercurial/smartset.py
changeset 36265 b44fac3a49fb
parent 35904 fc44c2657dc5
child 38261 f3033692ccef
--- a/mercurial/smartset.py	Thu Feb 15 17:14:45 2018 +0530
+++ b/mercurial/smartset.py	Sat Feb 17 18:09:56 2018 +0900
@@ -35,7 +35,7 @@
     elif callable(r):
         return r()
     else:
-        return pycompat.sysbytes(repr(r))
+        return pycompat.byterepr(r)
 
 def _typename(o):
     return pycompat.sysbytes(type(o).__name__).lstrip('_')
@@ -400,7 +400,7 @@
             # We fallback to the sorted version for a stable output.
             if self._ascending is not None:
                 l = self._asclist
-            s = pycompat.sysbytes(repr(l))
+            s = pycompat.byterepr(l)
         return '<%s%s %s>' % (_typename(self), d, s)
 
 class filteredset(abstractsmartset):
@@ -513,7 +513,7 @@
 
     @encoding.strmethod
     def __repr__(self):
-        xs = [pycompat.sysbytes(repr(self._subset))]
+        xs = [pycompat.byterepr(self._subset)]
         s = _formatsetrepr(self._condrepr)
         if s:
             xs.append(s)
@@ -1132,7 +1132,7 @@
 
 def prettyformat(revs):
     lines = []
-    rs = pycompat.sysbytes(repr(revs))
+    rs = pycompat.byterepr(revs)
     p = 0
     while p < len(rs):
         q = rs.find('<', p + 1)