Home GnuPG

Slightly improve some prose diffs
5d8e090fe1e2Unpublished

Unpublished Commit ยท Learn More

Repository Importing: This repository is still importing.

Description

Slightly improve some prose diffs

Summary:
Ref T7643. There are still some silly cases, but I think this improves behavior a bit:

  • At the top level, treat whitespace tokens separately. This significantly improves adding or removing paragraphs.
  • Fix a bug with diff construction where prefixes and suffixes could overlap on pure whitespace tokens.

There are still some other cases that we don't do a great job on but I think I need to adjust the approach a bit to really improve them.

Test Plan: Added a unit test with a pargraph addition, made it pass.

Reviewers: chad

Reviewed By: chad

Maniphest Tasks: T7643

Differential Revision: https://secure.phabricator.com/D16820

Details

Event Timeline

epriestley <git@epriestley.com> committed rPHUTIL5d8e090fe1e2: Slightly improve some prose diffs (authored by epriestley <git@epriestley.com>).Nov 7 2016, 11:54 PM