Skip to content

Commit 675fd40

Browse files
committed
update skip_on_cudasim to have messages, and update errors import to use vendored in numba.cuda.core.errors
1 parent 939e598 commit 675fd40

File tree

4 files changed

+5
-11
lines changed

4 files changed

+5
-11
lines changed

numba_cuda/numba/cuda/tests/test_array_attr.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
from numba.core import types
1111
from numba.cuda.tests.support import MemoryLeakMixin
1212
from numba.cuda.testing import CUDATestCase
13-
from numba.core.errors import TypingError
13+
from numba.cuda.core.errors import TypingError
1414
from numba.cuda.tests.support import override_config
1515
from numba.cuda import config
1616

numba_cuda/numba/cuda/tests/test_array_constants.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -118,7 +118,7 @@ def bytes_as_const_array_kernel(output_array, size):
118118
output_array[i] = 111 # 'o'
119119

120120

121-
@skip_on_cudasim
121+
@skip_on_cudasim("CUDA simulator does not support array constants")
122122
class TestConstantArray(CUDATestCase):
123123
"""
124124
Test array constants.
@@ -260,7 +260,7 @@ def big_array_kernel(input_array, output_array, size):
260260
np.testing.assert_array_equal(f_array.flatten(), result)
261261

262262

263-
@skip_on_cudasim
263+
@skip_on_cudasim("CUDA simulator does not support array constants")
264264
class TestConstantBytes(CUDATestCase):
265265
def test_constant_bytes(self):
266266
# Test constant bytes array in CUDA kernel

numba_cuda/numba/cuda/tests/test_array_iterators.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -617,7 +617,7 @@ def test_nditer3(self):
617617
def test_errors(self):
618618
# Incompatible shapes
619619
pyfunc = np_nditer2b_err
620-
cfunc = jit(debug=True)(pyfunc)
620+
cfunc = jit(debug=True, opt=False)(pyfunc)
621621

622622
self.disable_leak_check()
623623

numba_cuda/numba/cuda/typing/context.py

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -491,13 +491,7 @@ def is_external(obj):
491491
else:
492492
# A type was already inserted, see if we can add to it
493493
newty = existing.augment(gty)
494-
if (
495-
newty is None
496-
and ".".join(
497-
str(existing.__class__.__module__).split(".")[:2]
498-
)
499-
!= "numba.core"
500-
):
494+
if newty is None:
501495
raise TypeError(
502496
"cannot augment %s with %s" % (existing, gty)
503497
)

0 commit comments

Comments
 (0)