def METHOD_NAME(new_text: str, marks: Sequence[ExtMark]) -> Iterator[EditInstruction]:
    new_lines = new_text.splitlines()
    for mark in marks:
        if end := mark.end:
            yield EditInstruction(
                primary=False,
                begin=mark.begin,
                end=end,
                cursor_yoffset=0,
                cursor_xpos=-1,
                new_lines=new_lines,
            )