def METHOD_NAME(wrapped, *, cancel=False, return_exceptions=True):
    if wrapped.closed:
        raise RuntimeError("alru_cache is closed")
    wrapped.closed = True
    if cancel:
        for task in wrapped.tasks:
            if not task.done():  # not sure is it possible
                task.cancel()
    return _wait_closed(wrapped, return_exceptions=return_exceptions)