def find_next_character(code, position, char):
    """Find next char and return its first and last positions"""
    end = LineCol(code, *position)
    while not end.eof and end.char() in WHITESPACE:
        end.inc()

    if not end.eof and end.char() == char:
        return end.tuple(), inc_tuple(end.tuple())
    return None, None
def find_next_character ( code , position , char ) : end = LineCol ( code , * position ) while not end . eof and end . char ( ) in WHITESPACE : end . inc ( ) if not end . eof and end . char ( ) == char : return end . tuple ( ) , inc_tuple ( end . tuple ( ) ) return None , None
Find next char and return its first and last positions