def _loc(content, node):
    """
    Find the location of a node within ``content``

    Args:
        content (str): The file content
        node (ast.Node): Node to find

    Returns:
        (int, int): Start/end indices of string
    """
    start_line, start_col = node.lineno, node.col_offset
    end_line, end_col = node.end_lineno, node.end_col_offset
    line_lengths = [len(line) for line in content.splitlines(True)]

    idx0 = sum(line_lengths[: start_line - 1]) + start_col
    idx1 = sum(line_lengths[: end_line - 1]) + end_col

    return (idx0, idx1)