Skip to content

Commit

Permalink
Added casts to address compilation warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
oleksandr-pavlyk committed May 9, 2024
1 parent 65c1d3b commit 96e95f6
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions numba_dpex/core/runtime/_dpexrt_python.c
Original file line number Diff line number Diff line change
Expand Up @@ -842,7 +842,7 @@ static int DPEXRT_sycl_usm_ndarray_from_python(PyObject *obj,
}

if (!(arystruct->meminfo = NRT_MemInfo_new_from_usmndarray(
arrayobj, data, nitems, itemsize, qref)))
(PyObject *)arrayobj, data, nitems, itemsize, qref)))
{
DPEXRT_DEBUG(drt_debug_print(
"DPEXRT-ERROR: NRT_MemInfo_new_from_usmndarray failed "
Expand All @@ -855,7 +855,7 @@ static int DPEXRT_sycl_usm_ndarray_from_python(PyObject *obj,
arystruct->sycl_queue = qref;
arystruct->nitems = nitems;
arystruct->itemsize = itemsize;
arystruct->parent = arrayobj;
arystruct->parent = (PyObject *)arrayobj;

p = arystruct->shape_and_strides;

Expand Down Expand Up @@ -907,7 +907,7 @@ static int DPEXRT_sycl_usm_ndarray_from_python(PyObject *obj,
__FILE__, __LINE__));
gstate = PyGILState_Ensure();
// decref the python object
Py_XDECREF(arrayobj);
Py_XDECREF((PyObject *)arrayobj);
// release the GIL
PyGILState_Release(gstate);

Expand Down

0 comments on commit 96e95f6

Please sign in to comment.