import tokenize


def bracket_delta(token):
    """Returns +/-1 if the current token increases/decreases bracket nesting depth, 0 otherwise."""
    if token[0] == tokenize.OP and token[1] in ['{', '(', '[']:
        return 1
    elif token[0] == tokenize.OP and token[1] in ['}', ')', ']']:
        return -1
    else:
        return 0