diff options
Diffstat (limited to 'numpy')
| -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 |
