def bind_function(f, dispatcher, *accept_args, **accept_kwargs):
    """
    Bind a function to a dispatcher.

    Takes accept_args, and accept_kwargs and creates and ArgSpec instance,
    adding that to the MNDFunction which annotates the function


    :param f:  function to wrap
    :param accept_args:
    :param accept_kwargs:
    :return:
    """
    argspec = ArgSpec(None, *accept_args, **accept_kwargs)
    mnd = MNDFunction(f, dispatcher, argspec)
    f.__mnd__ = mnd
    return f
Bind a function to a dispatcher.

    Takes accept_args, and accept_kwargs and creates and ArgSpec instance,
    adding that to the MNDFunction which annotates the function


    :param f:  function to wrap
    :param accept_args:
    :param accept_kwargs:
    :return: