Skip to content

Commit f146dfa

Browse files
committed
Fix vi command invalidation
1 parent 551c03c commit f146dfa

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

Lib/_pyrepl/vi_commands.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -417,7 +417,7 @@ def do(self) -> None:
417417
if not pending_char or r.pos >= len(r.buffer):
418418
return
419419
r.buffer[r.pos] = pending_char
420-
r.dirty = True
420+
r.invalidate_buffer(r.pos)
421421

422422
class vi_replace_cancel(Command):
423423
"""Cancel pending replace operation."""
@@ -440,4 +440,4 @@ def do(self) -> None:
440440
state = r.undo_stack.pop()
441441
r.buffer[:] = state.buffer_snapshot
442442
r.pos = state.pos_snapshot
443-
r.dirty = True
443+
r.invalidate_buffer(0)

0 commit comments

Comments
 (0)