diff options
author | Matti Picus <matti.picus@gmail.com> | 2019-12-03 11:05:34 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-12-03 11:05:34 +0200 |
commit | fc860a2b279d5c370e2b332995b33528ebd97deb (patch) | |
tree | 3385c0992201b21f35cd3b0650746ee35d30961c | |
parent | 3a9a63f81aa37b48bc3eb4efdc2e695210805aa5 (diff) | |
parent | f0c6e41202e725debfe4c2a4694e791681210dbd (diff) | |
download | numpy-fc860a2b279d5c370e2b332995b33528ebd97deb.tar.gz |
Merge pull request #15032 from madphysicist/mintypecode-cleanup
MAINT: Cleaned up mintypecode for Py3 (pt. 2)
-rw-r--r-- | numpy/lib/type_check.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/numpy/lib/type_check.py b/numpy/lib/type_check.py index 8b9e4b8ab..977117235 100644 --- a/numpy/lib/type_check.py +++ b/numpy/lib/type_check.py @@ -75,7 +75,7 @@ def mintypecode(typechars, typeset='GDFgdf', default='d'): return default if 'F' in intersection and 'd' in intersection: return 'D' - return min((_typecodes_by_elsize.index(t), t) for t in intersection)[1] + return min(intersection, key=_typecodes_by_elsize.index) def _asfarray_dispatcher(a, dtype=None): |