Page MenuHomePhabricator

Slightly improve prose diffs for text ending in newlines or punctuation
ClosedPublic

Authored by epriestley on Jun 6 2016, 8:51 PM.
Tags
None
Referenced Files
F14033657: D16061.diff
Sat, Nov 9, 7:01 PM
F14021439: D16061.diff
Wed, Nov 6, 8:55 AM
F14014430: D16061.id.diff
Sun, Nov 3, 3:26 AM
F14010801: D16061.id38645.diff
Thu, Oct 31, 12:29 PM
F14008450: D16061.diff
Tue, Oct 29, 9:53 PM
F14003422: D16061.id38645.diff
Sat, Oct 26, 6:01 AM
F13984905: D16061.diff
Sun, Oct 20, 4:48 PM
Unknown Object (File)
Oct 9 2024, 3:58 AM
Subscribers
None

Details

Summary

Ref T3353. Currently, if text ends in newlines (or some other types of punctuation) we generate an extra piece at the end which can muck up the algorithm.

Do a slightly better job with this.

Test Plan

Viewed a diff between "a\nb\nc\n" and "a\nb\nc\nd\n", got a cleaner diff out of it.

Diff Detail

Repository
rPHU libphutil
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

epriestley retitled this revision from to Slightly improve prose diffs for text ending in newlines or punctuation.
epriestley updated this object.
epriestley edited the test plan for this revision. (Show Details)
epriestley added a reviewer: chad.
chad edited edge metadata.
This revision is now accepted and ready to land.Jun 6 2016, 8:58 PM
This revision was automatically updated to reflect the committed changes.