def nrt_adapt_ndarray_from_python(self, ary, ptr):
    assert self.context.enable_nrt
    fnty = Type.function(Type.int(), [self.pyobj, self.voidptr])
    fn = self._get_function(fnty, name='NRT_adapt_ndarray_from_python')
    fn.args[0].add_attribute(lc.ATTR_NO_CAPTURE)
    fn.args[1].add_attribute(lc.ATTR_NO_CAPTURE)
    return self.builder.call(fn, (ary, ptr))
def nrt_adapt_ndarray_from_python(self, ary, ptr):
    assert self.context.enable_nrt
    fnty = Type.function(Type.int(), [self.pyobj, self.voidptr])
    fn = self._get_function(fnty, name='NRT_adapt_ndarray_from_python')
    fn.args[0].add_attribute(lc.ATTR_NO_CAPTURE)
    fn.args[1].add_attribute(lc.ATTR_NO_CAPTURE)
    return self.builder.call(fn, (ary, ptr))