[PATCH 5 of 8] util: remove unused private constant '_hextochr'

Yuya Nishihara yuya at tcha.org
Thu Mar 22 11:01:56 EDT 2018


# HG changeset patch
# User Yuya Nishihara <yuya at tcha.org>
# Date 1521721939 -32400
#      Thu Mar 22 21:32:19 2018 +0900
# Node ID 6ddd0155f4708dc1e099f0d3e8f1c668ba6419e4
# Parent  fb052525a730ad7e2aeca8af22c4a66536921a79
util: remove unused private constant '_hextochr'

The only user, _urlunquote(), was removed by 81d38478fced.

diff --git a/mercurial/util.py b/mercurial/util.py
--- a/mercurial/util.py
+++ b/mercurial/util.py
@@ -34,7 +34,6 @@ import shutil
 import signal
 import socket
 import stat
-import string
 import subprocess
 import sys
 import tempfile
@@ -3076,9 +3075,6 @@ def parsebool(s):
     """
     return _booleans.get(s.lower(), None)
 
-_hextochr = dict((a + b, chr(int(a + b, 16)))
-                 for a in string.hexdigits for b in string.hexdigits)
-
 class url(object):
     r"""Reliable URL parser.
 


More information about the Mercurial-devel mailing list