Stefan Beller <stefanbeller@xxxxxxxxx> writes: > diff --git a/Documentation/config.txt b/Documentation/config.txt > index 0bcb679..f4f51c2 100644 > --- a/Documentation/config.txt > +++ b/Documentation/config.txt > @@ -980,8 +980,9 @@ color.diff.<slot>:: > of `context` (context text - `plain` is a historical synonym), > `meta` (metainformation), `frag` > (hunk header), 'func' (function in hunk header), `old` (removed lines), > - `new` (added lines), `commit` (commit headers), or `whitespace` > - (highlighting whitespace errors). > + `new` (added lines), `commit` (commit headers), `whitespace` > + (highlighting whitespace errors), `moved-old` (removed lines that > + reappear), `moved-new` (added lines that were removed elsewhere). Could we have a config to disable this rather costly new feature, too? Also the first and the third level configuration names (the <slot> is at the third level) used by the core-git do not use dashed-words format. Please adhere to the current convention. > diff --git a/diff.c b/diff.c > index 534c12e..d37cb4f 100644 > --- a/diff.c > +++ b/diff.c > @@ -18,6 +18,7 @@ > #include "ll-merge.h" > #include "string-list.h" > #include "argv-array.h" > +#include "git-compat-util.h" > > #ifdef NO_FAST_WORKING_DIRECTORY > #define FAST_WORKING_DIRECTORY 0 > @@ -42,6 +43,11 @@ static int diff_dirstat_permille_default = 30; > static struct diff_options default_diff_options; > static long diff_algorithm; > > +static struct hashmap *duplicates_added; > +static struct hashmap *duplicates_removed; > +static int hash_previous_line_added; > +static int hash_previous_line_removed; I think these should be added as new fields to diff_options structure.