From 3a573b5c601bae21aa6c9a4fd0716b27320f69c9 Mon Sep 17 00:00:00 2001 From: Sebastian Berg Date: Wed, 6 Jul 2022 18:57:36 -0700 Subject: Apply suggestions from code review --- numpy/core/function_base.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'numpy/core/function_base.py') diff --git a/numpy/core/function_base.py b/numpy/core/function_base.py index 178e6a26a..b5323fb17 100644 --- a/numpy/core/function_base.py +++ b/numpy/core/function_base.py @@ -143,7 +143,7 @@ def linspace(start, stop, num=50, endpoint=True, retstep=False, dtype=None, _mult_inplace = _nx.isscalar(delta) step = delta / div any_step_zero = ( - step == 0 if _mult_inplace else _nx.asarray(step == 0).any()) + step == 0 if _mult_inplace else _nx.asanyarray(step == 0).any()) if any_step_zero: # Special handling for denormal numbers, gh-5437 y /= div -- cgit v1.2.1