diff options
author | Pieter Eendebak <pieter.eendebak@gmail.com> | 2022-06-27 20:57:39 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-06-27 20:57:39 +0200 |
commit | dee44e6acef8e2151d5428bfeb6cbb64689340f9 (patch) | |
tree | 1f61f6b1dc94d4d3877e1bcd905146510d73f3f1 /numpy/core/function_base.py | |
parent | ece97833e1506f0223b9dcfa637d60640db75008 (diff) | |
download | numpy-dee44e6acef8e2151d5428bfeb6cbb64689340f9.tar.gz |
Update numpy/core/function_base.py
Co-authored-by: Sebastian Berg <sebastian@sipsolutions.net>
Diffstat (limited to 'numpy/core/function_base.py')
-rw-r--r-- | numpy/core/function_base.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/numpy/core/function_base.py b/numpy/core/function_base.py index baaf960de..178e6a26a 100644 --- a/numpy/core/function_base.py +++ b/numpy/core/function_base.py @@ -142,8 +142,8 @@ def linspace(start, stop, num=50, endpoint=True, retstep=False, dtype=None, if div > 0: _mult_inplace = _nx.isscalar(delta) step = delta / div - any_step_zero = step == 0 if _mult_inplace else \ - _nx.asarray(step == 0).any() + any_step_zero = ( + step == 0 if _mult_inplace else _nx.asarray(step == 0).any()) if any_step_zero: # Special handling for denormal numbers, gh-5437 y /= div |