[Python-checkins] distutils2: Remove unneeded function

tarek.ziade python-checkins at python.org
Sun Jan 30 10:43:57 CET 2011


tarek.ziade pushed cfa01cfd4666 to distutils2:

http://hg.python.org/distutils2/rev/cfa01cfd4666
changeset:   936:cfa01cfd4666
user:        ?ric Araujo <merwok at netwok.org>
date:        Sun Oct 31 15:34:45 2010 +0100
summary:
  Remove unneeded function

files:
  distutils2/_backport/pkgutil.py

diff --git a/distutils2/_backport/pkgutil.py b/distutils2/_backport/pkgutil.py
--- a/distutils2/_backport/pkgutil.py
+++ b/distutils2/_backport/pkgutil.py
@@ -966,12 +966,6 @@
     __hash__ = object.__hash__
 
 
-def _normalize_dist_name(name):
-    """Returns a normalized name from the given *name*.
-    :rtype: string"""
-    return name.replace('-', '_')
-
-
 def distinfo_dirname(name, version):
     """
     The *name* and *version* parameters are converted into their
@@ -991,7 +985,7 @@
     :returns: directory name
     :rtype: string"""
     file_extension = '.dist-info'
-    name = _normalize_dist_name(name)
+    name = name.replace('-', '_')
     normalized_version = suggest_normalized_version(version)
     # Because this is a lookup procedure, something will be returned even if
     #   it is a version that cannot be normalized

--
Repository URL: http://hg.python.org/distutils2


More information about the Python-checkins mailing list