@curry
def wrap(wrap_func, func, **kwargs):
    func_like = kwargs.pop('func_like', None)
    if (func_like is None):
        f = partial(wrap_func, func, **kwargs)
    else:
        f = partial(wrap_func, func_like, **kwargs)
    template = '\n    Blocked variant of %(name)s\n\n    Follows the signature of %(name)s exactly except that it also features\n    optional keyword arguments ``chunks: int, tuple, or dict`` and ``name: str``.\n\n    Original signature follows below.\n    '
    if (func.__doc__ is not None):
        f.__doc__ = ((template % {'name': func.__name__}) + func.__doc__)
        f.__name__ = ('blocked_' + func.__name__)
    return f
@curry
def wrap(wrap_func, func, **kwargs):
    func_like = kwargs.pop('func_like', None)
    if (func_like is None):
        f = partial(wrap_func, func, **kwargs)
    else:
        f = partial(wrap_func, func_like, **kwargs)
    template = '\n    Blocked variant of %(name)s\n\n    Follows the signature of %(name)s exactly except that it also features\n    optional keyword arguments ``chunks: int, tuple, or dict`` and ``name: str``.\n\n    Original signature follows below.\n    '
    if (func.__doc__ is not None):
        f.__doc__ = ((template % {'name': func.__name__}) + func.__doc__)
        f.__name__ = ('blocked_' + func.__name__)
    return f