summaryrefslogtreecommitdiff
path: root/numpy/core/fromnumeric.py
diff options
context:
space:
mode:
authorCharles Harris <charlesr.harris@gmail.com>2017-08-26 10:41:54 -0500
committerGitHub <noreply@github.com>2017-08-26 10:41:54 -0500
commit813a14c7f702cfe64faf6cfbcb72d138e600bffd (patch)
treee14c474d817af2ede29dee0fb94ae29556105dfa /numpy/core/fromnumeric.py
parenta79f78e46154a8a1026c00dbba333b23781ba470 (diff)
parentbe08980377cf2cd0c136e32eb0c644d392e5c7be (diff)
downloadnumpy-813a14c7f702cfe64faf6cfbcb72d138e600bffd.tar.gz
Merge pull request #9611 from srinivasreddy/rm_exception
MAINT: remove try..except clause.
Diffstat (limited to 'numpy/core/fromnumeric.py')
-rw-r--r--numpy/core/fromnumeric.py7
1 files changed, 1 insertions, 6 deletions
diff --git a/numpy/core/fromnumeric.py b/numpy/core/fromnumeric.py
index 10b20c0b1..6f7c45859 100644
--- a/numpy/core/fromnumeric.py
+++ b/numpy/core/fromnumeric.py
@@ -28,12 +28,7 @@ __all__ = [
'std', 'sum', 'swapaxes', 'take', 'trace', 'transpose', 'var',
]
-
-try:
- _gentype = types.GeneratorType
-except AttributeError:
- _gentype = type(None)
-
+_gentype = types.GeneratorType
# save away Python sum
_sum_ = sum