def _make_deferred_unary_ufunc(ufunc: unary_ufunc) -> Callable[..., Any]:
    """Factory that creates deferred ufunc methods.

    Args:
        ufunc: function from the ``_ufunc`` module
        (e.g., ``_ufunc.negative``)

    Returns:
        A fully-formed ufunc method with deferred execution support
    """

    def ufunc_method(self: Any, *args: Any, **kwargs: Any) -> Any:
        from .._array.array import ndarray  # Lazy import inside function

        a = ndarray(self.shape, self.dtype, thunk=self)
        return ufunc._call_full(a, *args, **kwargs)

    return ufunc_method
Factory that creates deferred ufunc methods.

    Args:
        ufunc: function from the ``_ufunc`` module
        (e.g., ``_ufunc.negative``)

    Returns:
        A fully-formed ufunc method with deferred execution support
    
cupynumeric/_thunk/deferred.py