audiosegment.py
def deprecated(func):
    """
    Deprecator decorator.
    """
    @functools.wraps(func)
    def new_func(*args, **kwargs):
        warnings.warn("Call to deprecated function {}.".format(func.__name__), category=DeprecationWarning, stacklevel=2)
        return func(*args, **kwargs)

    return new_func
def deprecated(func):
    """
    Deprecator decorator.
    """
    @functools.wraps(func)
    def new_func(*args, **kwargs):
        warnings.warn("Call to deprecated function {}.".format(func.__name__), category=DeprecationWarning, stacklevel=2)
        return func(*args, **kwargs)

    return new_func
def deprecated ( func ) : @ functools . wraps ( func ) def new_func ( * args , * * kwargs ) : warnings . warn ( "Call to deprecated function {}." . format ( func . __name__ ) , category = DeprecationWarning , stacklevel = 2 ) return func ( * args , * * kwargs ) return new_func
Deprecator decorator.
Deprecator decorator .