We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 4afd698 commit 3e2ea1cCopy full SHA for 3e2ea1c
dpctl/memory/_sycl_usm_array_interface_utils.pxi
@@ -89,6 +89,8 @@ cdef object _pointers_from_shape_and_stride(
89
for i in range(nd):
90
str_i = int(ary_strides[i])
91
sh_i = int(ary_shape[i])
92
+ if (sh_i <= 0):
93
+ raise ValueError("Array shape elements need to be positive")
94
if (str_i > 0):
95
max_disp += str_i * (sh_i - 1)
96
else:
0 commit comments