summaryrefslogtreecommitdiff
path: root/numpy/lib/utils.py
diff options
context:
space:
mode:
authornjsmith <njs@pobox.com>2013-04-25 06:20:09 -0700
committernjsmith <njs@pobox.com>2013-04-25 06:20:09 -0700
commit0291896c63201f56279c8835c59ed73fee4e1916 (patch)
treeed0b65a13f4b1944423c6b5548c3f2ae5d2323b6 /numpy/lib/utils.py
parent65c172fda22c330773bac59fb7cf5e82a0938a63 (diff)
parentc92d924dd3dfa9eb97f65848e04ec9391709bc09 (diff)
downloadnumpy-0291896c63201f56279c8835c59ed73fee4e1916.tar.gz
Merge pull request #3268 from charris/maint-remove-unneeded-version-checks
MAINT: Remove unneeded version checks.
Diffstat (limited to 'numpy/lib/utils.py')
-rw-r--r--numpy/lib/utils.py15
1 files changed, 4 insertions, 11 deletions
diff --git a/numpy/lib/utils.py b/numpy/lib/utils.py
index 75ba5bca6..2519cd4d4 100644
--- a/numpy/lib/utils.py
+++ b/numpy/lib/utils.py
@@ -84,17 +84,10 @@ def get_numarray_include(type=None):
return include_dirs + [get_include()]
-if sys.version_info < (2, 4):
- # Can't set __name__ in 2.3
- import new
- def _set_function_name(func, name):
- func = new.function(func.__code__, func.__globals__,
- name, func.__defaults__, func.__closure__)
- return func
-else:
- def _set_function_name(func, name):
- func.__name__ = name
- return func
+def _set_function_name(func, name):
+ func.__name__ = name
+ return func
+
class _Deprecate(object):
"""