From b70c9e6cc29fffc0a1eddfe44c2cea3d6c119aa9 Mon Sep 17 00:00:00 2001 From: Sergey Pokhodenko Date: Mon, 9 Nov 2020 23:48:42 +0300 Subject: [PATCH] Extending typing context Changed in 7ccc8e3 by @reazulhoque. --- numba/core/typing/context.py | 13 ++----------- 1 file changed, 2 insertions(+), 11 deletions(-) diff --git a/numba/core/typing/context.py b/numba/core/typing/context.py index 09f27862d54..720cbbb258e 100644 --- a/numba/core/typing/context.py +++ b/numba/core/typing/context.py @@ -352,17 +352,8 @@ def resolve_argument_type(self, val): try: return typeof(val, Purpose.argument) except ValueError: - from numba.dppl_config import dppl_present, DeviceArray - if dppl_present: - if(type(val) == DeviceArray): - return typeof(val._ndarray, Purpose.argument) - # DRD : Hmmm... is the assumption that this error is encountered - # when someone is using cuda, and already has done an import - # cuda? - #elif numba.cuda.is_cuda_array(val): - # return typeof(numba.cuda.as_cuda_array(val), Purpose.argument) - else: - raise + if numba.cuda.is_cuda_array(val): + return typeof(numba.cuda.as_cuda_array(val), Purpose.argument) else: raise