import asyncio


def iscoro_or_corofunc(x):
    """
    Returns ``True`` if the given value is a coroutine or a coroutine function.

    Arguments:
        x (mixed): object value to assert.

    Returns:
        bool: returns ``True`` if ``x` is a coroutine or coroutine function.
    """
    return asyncio.iscoroutinefunction(x) or asyncio.iscoroutine(x)