FAILURE MAP
← Case archive

FA-75725 / Text diff and three-way merge / Member archive

Patch reversal: no-newline markers detach from their lines · case 05

After reordering, the missing-newline marker follows the wrong line or starts a block.

Member previewVariant 5 · 3 implementations · 8 checks per implementation

Case contract

Reverse one unified hunk: swap the old and new ranges in the header, keeping each range's count omitted if it was omitted and keeping any trailing header text; swap "-" and "+" on body lines; within each run of changed lines emit the (new) removed lines before the (new) added lines; a "\" marker line stays attached to the line it follows.

Why this case matters

Reverting a change applies the reversed patch, which must still be a valid, conventionally ordered hunk.

One recorded failure

Sample boundary fixture

This sample comes from the broken implementation of a controlled reproducer.

Boundary fixtureActualExpectedOutcome
no-newline marker follows its line["@@ -1,2 +1,2 @@", " k", "+old", "\\ No newline at end of file", "-new", "\\ No newline at end of file"]["@@ -1,2 +1,2 @@", " k", "-new", "\\ No newline at end of file", "+old", "\\ No newline at end of file"]Failed

MEMBER ARCHIVE

The complete case is available to members.

This record includes three runnable implementations, regression fixtures, execution results, and source hashes.

Member access is invitation-based. Sign in with your invited account to inspect the sources.

Sign in to the archive ↗