Stefan Beller <[email protected]> writes:
>> -diff.indentHeuristic::
>> diff.compactionHeuristic::
>> Set one of these options to `true` to enable one of two
>> experimental heuristics that shift diff hunk boundaries to
>
> We would need to reword this as well, as there will be only one heuristic
> left?
>> + } else if (flags & XDF_COMPACTION_HEURISTIC) {
>> /*
>> * Indent heuristic: a group of pure add/delete lines
>
> This comment may need adjustment as well (though we could go without)
Thanks. I've queued this as "SQUASH???" on top.
diff --git a/Documentation/diff-config.txt b/Documentation/diff-config.txt
index 0c79e48d9d..39fff3aef9 100644
--- a/Documentation/diff-config.txt
+++ b/Documentation/diff-config.txt
@@ -172,9 +172,8 @@ diff.tool::
include::mergetools-diff.txt[]
diff.compactionHeuristic::
- Set one of these options to `true` to enable one of two
- experimental heuristics that shift diff hunk boundaries to
- make patches easier to read.
+ Set this option to `true` to enable experimental heuristics
+ that shift diff hunk boundaries to make patches easier to read.
diff.algorithm::
Choose a diff algorithm. The variants are as follows:
diff --git a/xdiff/xdiffi.c b/xdiff/xdiffi.c
index 6cb96219cb..31ff519232 100644
--- a/xdiff/xdiffi.c
+++ b/xdiff/xdiffi.c
@@ -908,7 +908,9 @@ int xdl_change_compact(xdfile_t *xdf, xdfile_t *xdfo, long
flags) {
}
} else if (flags & XDF_COMPACTION_HEURISTIC) {
/*
- * Indent heuristic: a group of pure add/delete lines
+ * Heuristic based on the indentation level.
+ *
+ * A group of pure add/delete lines
* implies two splits, one between the end of the
"before"
* context and the start of the group, and another
between
* the end of the group and the beginning of the "after"