fix: Correct spacing in patch_coder.py for accurate matching

This commit is contained in:
Paul Gauthier (aider) 2025-04-14 14:36:54 -07:00
parent 6b75a578ac
commit 97e2a7bae0

View file

@ -126,7 +126,8 @@ class PatchCoder(Coder):
if current_action.type == ActionType.UPDATE:
# This simplified parser doesn't handle @@ context or chunk boundaries well.
# It assumes a simple sequence of context, '-', '+' lines per chunk.
# A real implementation needs the state machine from apply_patch.py's peek_next_section.
# A real implementation needs the state machine from apply_patch.py's
# peek_next_section.
# Placeholder: treat consecutive -,+ blocks as single chunk for simplicity.
if not current_action.chunks:
current_action.chunks.append(Chunk()) # Start first chunk