Skip to content

Commit 9053822

Browse files
Change to .asarray
Co-authored-by: Lucas Colley <[email protected]>
1 parent ef799ed commit 9053822

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/array_api_extra/_delegation.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -166,7 +166,7 @@ def nan_to_num(
166166
>>> xpx.nan_to_num(x)
167167
array([ 1.79769313e+308, -1.79769313e+308, 0.00000000e+000, # may vary
168168
-1.28000000e+002, 1.28000000e+002])
169-
>>> y = xp.array([complex(xp.inf, xp.nan), xp.nan, complex(xp.nan, xp.inf)])
169+
>>> y = xp.asarray([complex(xp.inf, xp.nan), xp.nan, complex(xp.nan, xp.inf)])
170170
array([ 1.79769313e+308, -1.79769313e+308, 0.00000000e+000, # may vary
171171
-1.28000000e+002, 1.28000000e+002])
172172
>>> xpx.nan_to_num(y)

0 commit comments

Comments
 (0)