Do not mark "distinct" diff nodes as being redundant
When a char is changed into a const char several times in different
spots of the type graph, we want to see all the occurence of those
changes. Generalizing this in Abigail parlance, we'd say that we want
to see all occurences of distinct diff nodes, so we don't want to mark
them as being redundant.
Right now, libabigail will only show the first occurence of that
change will flag subsequent onces as being redundant, by virtue of the
redundancy marking pass.
This patch avoids marking distinct diff nodes as being redundant.
This patch is part of the set of patches whose titles are:
Do not show decl-only-to-def changes in the leaf reporter
Overhaul of the report diff stats summary
Do not mark "distinct" diff nodes as being redundant
Fix meaning of "harmless name change" to avoid overfiltering
Better handle category propagation of pointer changes
Improve function changes reporting in leaf and default mode
Don't filter out typedef changes with redundant underlying type changes
Only show leaf type changes in the leaf type changes section
Fix leaf report of class data member changes
Always show redundant changes in leaf mode
Avoid reporting an enum change if it has already been reported
When we say an a change was reported earlier give its source location
[abipkgdiff]: in leaf mode we always show redundant changes
Update tests for the "better leaf mode redundancy management" patchset
* include/abg-comp-filter.h (is_mostly_distinct_diff): Declare new
function.
* include/abg-fwd.h (peel_typedef_pointer_or_reference_type): Take
a boolean to decide to peel qualified types or not.
* src/abg-comp-filter.cc (is_mostly_distinct_diff): Define this function.
* src/abg-comparison.cc (redundancy_marking_visitor::visit_begin):
Do not mark distinct_diff nodes as being redundant.
* src/abg-ir.cc (peel_typedef_pointer_or_reference_type):
Implement taking a boolean to decide to peel qualified types or
not.