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
F13059805: D16061.diff
Fri, Apr 19, 4:51 PM
Unknown Object (File)
Wed, Apr 17, 5:01 AM
Unknown Object (File)
Tue, Apr 9, 8:32 AM
Unknown Object (File)
Wed, Apr 3, 8:50 AM
Unknown Object (File)
Sun, Mar 31, 11:42 PM
Unknown Object (File)
Sun, Mar 31, 2:31 PM
Unknown Object (File)
Thu, Mar 28, 11:24 AM
Unknown Object (File)
Thu, Mar 28, 8:06 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.