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

login
register
mail settings
Submitter Yuya Nishihara
Date March 22, 2018, 3:01 p.m.
Message ID <6ddd0155f4708dc1e099.1521730916@mimosa>
Download mbox | patch
Permalink /patch/29784/
State Accepted
Headers show

Comments

Yuya Nishihara - March 22, 2018, 3:01 p.m.
# HG changeset patch
# User Yuya Nishihara <yuya@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.

Patch

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.