[PATCH v3 0/3] "diff --color-moved" with different heuristic
- From
- Jonathan Tan <jonathantanmy@google.com>
- Date
- Aug 14, 2017, 23:57 UTC
- Message-ID
- <cover.1502754962.git.jonathantanmy@google.com>
- In-Reply-To
- <cover.1502491372.git.jonathantanmy@google.com>
These patches are on sb/diff-color-move.
Patches 1 and 2 are unchanged.
If we're planning to cook a heuristic, we might as well try a better one. What do you think of this? A heuristic of number of non-whitespace characters, applied at the block level, and not dependent on the block's neighbors.
As for the test, good point about testing the boundary conditions - I have included another test that does that.
Jonathan Tan (3): diff: avoid redundantly clearing a flag diff: respect MIN_BLOCK_LENGTH for last block diff: define block by number of non-space chars
Documentation/diff-options.txt | 8 +-- diff.c | 44 +++++++++++--- diff.h | 2 +- t/t4015-diff-whitespace.sh | 129 +++++++++++++++++++++++++++++++++++++++-- 4 files changed, 163 insertions(+), 20 deletions(-)
-- 2.14.1.480.gb18f417b89-goog