libabigail/tests/data/test-abicompat
Dodji Seketeli 2f92777dc8 Consider the implicit 'this' parameter when comparing methods
Since 2013 the implicit 'this' parameter has been excluded from the
function parameters taken into account while comparing class member
functions.  This was an early measure to avoid infinite recursion that
would then occur when comparing classes (and thus their member
functions that are referenced in their vtable).  But since then, we've
built descent infrastructure to prevent this kind of recursion in a
more generic manner.

This patch thus removes that restriction and should therefore lift the
concerns expressed in the bug
https://sourceware.org/bugzilla/show_bug.cgi?id=26672.

Namely, changes to (data members of) a class should now be detected
when comparing member functions of that class.

With this change, the reference output of several comparison
regression tests changed because, obviously, some impacted member
functions are now reported along with detecting changes in data
membrers of classes.  The patch thus adjusts those reference ouputs.

The patch also adjust the behaviour of the predicate:
  "accessed_through = pointer|reference|reference-or-pointer"
The idea is to make the predicate work on qualified version of a type.

	* include/abg-ir.h (function_type::get_first_parm): Declare new
	accessor.
	* src/abg-ir.cc (function_type::get_first_parm): Define new
	accessor.
	(equals): In the overload for function_type,
	always take the implicit "this" parameter into account in
	parameter comparisons.
	(function_type::get_first_non_implicit_parm): Adjust comment.
	* src/abg-comp-filter.cc (function_name_changed_but_not_symbol):
	Avoid potential NULL pointer dereferencing.
	* src/abg-comparison.cc
	(function_type_diff::ensure_lookup_tables_populated): Always take
	the changes to the implicit 'this' parameter into account in the
	function type diff.
	(compute_diff): In the overload for function_type, Always compare
	the implicit 'this' parameter when comparing function parameters.
	* src/abg-default-reporter.cc (default_reporter::report): Refer to
	"implicit parameter" when reporting changes on parameters
	artificially generated by the compiler.
	* src/abg-suppression.cc (type_suppression::suppresses_diff): Make
	the 'access_through' predicate work on a qualified version of type
	'S', even if it was meant to work on type 'S'.  This allows it to
	work on 'const S', especially when S is accessed through 'pointer
	to const S', which happens when we consider the implicit 'this'
	parameter of a const member function.
	* tests/data/test-abicompat/test5-fn-changed-report-0.txt: Adjust.
	* tests/data/test-abicompat/test5-fn-changed-report-1.txt: Likewise.
	* tests/data/test-abidiff-exit/test1-voffset-change-report0.txt:
	Likewise.
	* tests/data/test-abidiff/test-PR18791-report0.txt: Likewise.
	* tests/data/test-abidiff/test-struct1-report.txt: Likewise.
	* tests/data/test-diff-dwarf-abixml/test0-pr19026-libvtkIOSQL-6.1.so.1-report-0.txt:
	Likewise.
	* tests/data/test-diff-dwarf/test0-report.txt: Likewise.
	* tests/data/test-diff-dwarf/test28-vtable-changes-report-0.txt: Likewise.
	* tests/data/test-diff-dwarf/test29-vtable-changes-report-0.txt: Likewise.
	* tests/data/test-diff-dwarf/test30-vtable-changes-report-0.txt: Likewise.
	* tests/data/test-diff-dwarf/test31-vtable-changes-report-0.txt: Likewise.
	* tests/data/test-diff-dwarf/test36-ppc64-aliases-report-0.txt: Likewise.
	* tests/data/test-diff-dwarf/test41-PR20476-hidden-report-0.txt: Likewise.
	* tests/data/test-diff-dwarf/test42-PR21296-clanggcc-report0.txt: Likewise.
	* tests/data/test-diff-dwarf/test5-report.txt: Likewise.
	* tests/data/test-diff-dwarf/test8-report.txt: Likewise.
	* tests/data/test-diff-filter/test0-report.txt: Likewise.
	* tests/data/test-diff-filter/test01-report.txt: Likewise.
	* tests/data/test-diff-filter/test10-report.txt: Likewise.
	* tests/data/test-diff-filter/test13-report.txt: Likewise.
	* tests/data/test-diff-filter/test2-report.txt: Likewise.
	* tests/data/test-diff-filter/test28-redundant-and-filtered-children-nodes-report-0.txt:
	Likewise.
	* tests/data/test-diff-filter/test28-redundant-and-filtered-children-nodes-report-1.txt:
	Likewise.
	* tests/data/test-diff-filter/test30-pr18904-rvalueref-report0.txt:
	Likewise.
	* tests/data/test-diff-filter/test30-pr18904-rvalueref-report1.txt:
	Likewise.
	* tests/data/test-diff-filter/test30-pr18904-rvalueref-report2.txt:
	Likewise.
	* tests/data/test-diff-filter/test31-pr18535-libstdc++-report-0.txt:
	Likewise.
	* tests/data/test-diff-filter/test31-pr18535-libstdc++-report-1.txt:
	Likewise.
	* tests/data/test-diff-filter/test35-pr18754-no-added-syms-report-0.txt:
	Likewise.
	* tests/data/test-diff-filter/test35-pr18754-no-added-syms-report-1.txt:
	Likewise.
	* tests/data/test-diff-filter/test4-report.txt: Likewise.
	* tests/data/test-diff-filter/test41-report-0.txt: Likewise.
	* tests/data/test-diff-filter/test9-report.txt: Likewise.
	* tests/data/test-diff-pkg/libsigc++-2.0-0c2a_2.4.0-1_amd64--libsigc++-2.0-0v5_2.4.1-1ubuntu2_amd64-report-0.txt:
	Likewise.
	* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-0.txt:
	Likewise.
	* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-1.txt:
	Likewise.
	* tests/data/test-diff-suppr/test24-soname-report-0.txt: Likewise.
	* tests/data/test-diff-suppr/test24-soname-report-1.txt: Likewise.
	* tests/data/test-diff-suppr/test24-soname-report-10.txt: Likewise.
	* tests/data/test-diff-suppr/test24-soname-report-11.txt: Likewise.
	* tests/data/test-diff-suppr/test24-soname-report-12.txt: Likewise.
	* tests/data/test-diff-suppr/test24-soname-report-13.txt: Likewise.
	* tests/data/test-diff-suppr/test24-soname-report-14.txt: Likewise.
	* tests/data/test-diff-suppr/test24-soname-report-15.txt: Likewise.
	* tests/data/test-diff-suppr/test24-soname-report-16.txt: Likewise.
	* tests/data/test-diff-suppr/test24-soname-report-2.txt: Likewise.
	* tests/data/test-diff-suppr/test24-soname-report-3.txt: Likewise.
	* tests/data/test-diff-suppr/test24-soname-report-4.txt: Likewise.
	* tests/data/test-diff-suppr/test24-soname-report-5.txt: Likewise.
	* tests/data/test-diff-suppr/test24-soname-report-6.txt: Likewise.
	* tests/data/test-diff-suppr/test24-soname-report-7.txt: Likewise.
	* tests/data/test-diff-suppr/test24-soname-report-8.txt: Likewise.
	* tests/data/test-diff-suppr/test24-soname-report-9.txt: Likewise.
	* tests/data/test-diff-suppr/test31-report-1.txt: Likewise.
	* tests/data/test-diff-suppr/test33-report-0.txt: Likewise.

Signed-off-by: Dodji Seketeli <dodji@redhat.com>
2020-10-09 11:05:23 +02:00
..
libtest0-fn-changed-libapp-v0.so Initial implementation of the abicompat tool 2014-12-05 15:43:31 +01:00
libtest0-fn-changed-libapp-v1.so Initial implementation of the abicompat tool 2014-12-05 15:43:31 +01:00
libtest1-fn-removed-v0.so Initial implementation of the abicompat tool 2014-12-05 15:43:31 +01:00
libtest1-fn-removed-v1.so Initial implementation of the abicompat tool 2014-12-05 15:43:31 +01:00
libtest2-var-removed-v0.so Initial implementation of the abicompat tool 2014-12-05 15:43:31 +01:00
libtest2-var-removed-v1.so Initial implementation of the abicompat tool 2014-12-05 15:43:31 +01:00
libtest3-fn-removed-v0.so Initial implementation of the abicompat tool 2014-12-05 15:43:31 +01:00
libtest3-fn-removed-v1.so Initial implementation of the abicompat tool 2014-12-05 15:43:31 +01:00
libtest4-soname-changed-v0.so Wire the soname check into abicompat 2014-12-08 13:47:00 +01:00
libtest4-soname-changed-v1.so Wire the soname check into abicompat 2014-12-08 13:47:00 +01:00
libtest5-fn-changed-libapp-v0.so Add support for abicompat weak mode 2015-04-03 22:45:41 +02:00
libtest5-fn-changed-libapp-v1.so Add support for abicompat weak mode 2015-04-03 22:45:41 +02:00
libtest6-var-changed-libapp-v0.so Add support for abicompat weak mode 2015-04-03 22:45:41 +02:00
libtest6-var-changed-libapp-v1.so Add support for abicompat weak mode 2015-04-03 22:45:41 +02:00
libtest7-fn-changed-libapp-v0.so Fix computing the set of exported functions and varible symbols 2015-07-20 12:46:21 +02:00
libtest7-fn-changed-libapp-v1.so Fix computing the set of exported functions and varible symbols 2015-07-20 12:46:21 +02:00
libtest8-fn-changed-libapp-v0.so Fix synthesizing of pointer type 2016-02-03 13:00:51 +01:00
libtest8-fn-changed-libapp-v1.so Fix synthesizing of pointer type 2016-02-03 13:00:51 +01:00
libtest9-fn-changed-v0.so Fix synthesizing of reference type 2016-02-04 11:26:22 +01:00
libtest9-fn-changed-v1.so Fix synthesizing of reference type 2016-02-04 11:26:22 +01:00
test0-fn-changed-0.suppr Initial implementation of the abicompat tool 2014-12-05 15:43:31 +01:00
test0-fn-changed-1.suppr Implement a [suppress_file] suppression directive 2016-05-08 12:39:26 +02:00
test0-fn-changed-app Add support for abicompat weak mode 2015-04-03 22:45:41 +02:00
test0-fn-changed-app.cc Initial implementation of the abicompat tool 2014-12-05 15:43:31 +01:00
test0-fn-changed-libapp-v0.cc Initial implementation of the abicompat tool 2014-12-05 15:43:31 +01:00
test0-fn-changed-libapp-v1.cc Initial implementation of the abicompat tool 2014-12-05 15:43:31 +01:00
test0-fn-changed-libapp.h Initial implementation of the abicompat tool 2014-12-05 15:43:31 +01:00
test0-fn-changed-report-0.txt abidiff: Clean up new lines between sections. 2020-03-30 16:26:31 +02:00
test0-fn-changed-report-1.txt Initial implementation of the abicompat tool 2014-12-05 15:43:31 +01:00
test0-fn-changed-report-2.txt abidiff: Clean up new lines between sections. 2020-03-30 16:26:31 +02:00
test0-fn-changed-report-3.txt Implement a [suppress_file] suppression directive 2016-05-08 12:39:26 +02:00
test1-fn-removed-app Initial implementation of the abicompat tool 2014-12-05 15:43:31 +01:00
test1-fn-removed-app.cc Initial implementation of the abicompat tool 2014-12-05 15:43:31 +01:00
test1-fn-removed-report-0.txt Tag add/remove/change lines unconditionally with [A], [D], [C]. 2020-03-18 14:45:26 +01:00
test1-fn-removed-v0.cc Initial implementation of the abicompat tool 2014-12-05 15:43:31 +01:00
test1-fn-removed-v1.cc Initial implementation of the abicompat tool 2014-12-05 15:43:31 +01:00
test2-var-removed-app Initial implementation of the abicompat tool 2014-12-05 15:43:31 +01:00
test2-var-removed-app.cc Initial implementation of the abicompat tool 2014-12-05 15:43:31 +01:00
test2-var-removed-report-0.txt Tag add/remove/change lines unconditionally with [A], [D], [C]. 2020-03-18 14:45:26 +01:00
test2-var-removed-v0.cc Initial implementation of the abicompat tool 2014-12-05 15:43:31 +01:00
test2-var-removed-v1.cc Initial implementation of the abicompat tool 2014-12-05 15:43:31 +01:00
test3-fn-removed-app Initial implementation of the abicompat tool 2014-12-05 15:43:31 +01:00
test3-fn-removed-app.cc Initial implementation of the abicompat tool 2014-12-05 15:43:31 +01:00
test3-fn-removed-report-0.txt Tag add/remove/change lines unconditionally with [A], [D], [C]. 2020-03-18 14:45:26 +01:00
test3-fn-removed-v0.cc Initial implementation of the abicompat tool 2014-12-05 15:43:31 +01:00
test3-fn-removed-v1.cc Initial implementation of the abicompat tool 2014-12-05 15:43:31 +01:00
test3-fn-removed-version-script-0 Initial implementation of the abicompat tool 2014-12-05 15:43:31 +01:00
test3-fn-removed-version-script-1 Initial implementation of the abicompat tool 2014-12-05 15:43:31 +01:00
test4-soname-changed-app Wire the soname check into abicompat 2014-12-08 13:47:00 +01:00
test4-soname-changed-app.cc Wire the soname check into abicompat 2014-12-08 13:47:00 +01:00
test4-soname-changed-report-0.txt Wire the soname check into abicompat 2014-12-08 13:47:00 +01:00
test4-soname-changed-v0.cc Wire the soname check into abicompat 2014-12-08 13:47:00 +01:00
test4-soname-changed-v1.cc Wire the soname check into abicompat 2014-12-08 13:47:00 +01:00
test5-fn-changed-app Add support for abicompat weak mode 2015-04-03 22:45:41 +02:00
test5-fn-changed-app.cc Add support for abicompat weak mode 2015-04-03 22:45:41 +02:00
test5-fn-changed-libapp-v0.cc Add support for abicompat weak mode 2015-04-03 22:45:41 +02:00
test5-fn-changed-libapp-v0.h Add support for abicompat weak mode 2015-04-03 22:45:41 +02:00
test5-fn-changed-libapp-v1.cc Add support for abicompat weak mode 2015-04-03 22:45:41 +02:00
test5-fn-changed-libapp-v1.h Add support for abicompat weak mode 2015-04-03 22:45:41 +02:00
test5-fn-changed-report-0.txt Consider the implicit 'this' parameter when comparing methods 2020-10-09 11:05:23 +02:00
test5-fn-changed-report-1.txt Consider the implicit 'this' parameter when comparing methods 2020-10-09 11:05:23 +02:00
test6-var-changed-app Add support for abicompat weak mode 2015-04-03 22:45:41 +02:00
test6-var-changed-app.cc Add support for abicompat weak mode 2015-04-03 22:45:41 +02:00
test6-var-changed-libapp-v0.cc Add support for abicompat weak mode 2015-04-03 22:45:41 +02:00
test6-var-changed-libapp-v0.h Add support for abicompat weak mode 2015-04-03 22:45:41 +02:00
test6-var-changed-libapp-v1.cc Add support for abicompat weak mode 2015-04-03 22:45:41 +02:00
test6-var-changed-libapp-v1.h Add support for abicompat weak mode 2015-04-03 22:45:41 +02:00
test6-var-changed-report-0.txt Eliminate some unnecessary blank lines in diff output. 2020-03-16 16:15:09 +01:00
test6-var-changed-report-1.txt Eliminate some unnecessary blank lines in diff output. 2020-03-16 16:15:09 +01:00
test7-fn-changed-app Fix computing the set of exported functions and varible symbols 2015-07-20 12:46:21 +02:00
test7-fn-changed-app.c Fix computing the set of exported functions and varible symbols 2015-07-20 12:46:21 +02:00
test7-fn-changed-libapp-v0.c Fix computing the set of exported functions and varible symbols 2015-07-20 12:46:21 +02:00
test7-fn-changed-libapp-v0.h Fix computing the set of exported functions and varible symbols 2015-07-20 12:46:21 +02:00
test7-fn-changed-libapp-v1.c Fix computing the set of exported functions and varible symbols 2015-07-20 12:46:21 +02:00
test7-fn-changed-libapp-v1.h Fix computing the set of exported functions and varible symbols 2015-07-20 12:46:21 +02:00
test7-fn-changed-report-0.txt abidiff: Clean up new lines between sections. 2020-03-30 16:26:31 +02:00
test7-fn-changed-report-1.txt Represent sizes and offsets in bytes and hexadecimal values 2018-04-30 17:11:40 +02:00
test7-fn-changed-report-2.txt Represent sizes and offsets in bytes and hexadecimal values 2018-04-30 17:11:40 +02:00
test8-fn-changed-app Fix synthesizing of pointer type 2016-02-03 13:00:51 +01:00
test8-fn-changed-app.c Fix synthesizing of pointer type 2016-02-03 13:00:51 +01:00
test8-fn-changed-libapp-v0.c Fix synthesizing of pointer type 2016-02-03 13:00:51 +01:00
test8-fn-changed-libapp-v0.h Fix synthesizing of pointer type 2016-02-03 13:00:51 +01:00
test8-fn-changed-libapp-v1.c Fix synthesizing of pointer type 2016-02-03 13:00:51 +01:00
test8-fn-changed-libapp-v1.h Fix synthesizing of pointer type 2016-02-03 13:00:51 +01:00
test8-fn-changed-report-0.txt Represent sizes and offsets in bytes and hexadecimal values 2018-04-30 17:11:40 +02:00
test9-fn-changed-app Fix synthesizing of reference type 2016-02-04 11:26:22 +01:00
test9-fn-changed-app.cc Fix synthesizing of reference type 2016-02-04 11:26:22 +01:00
test9-fn-changed-report-0.txt Represent sizes and offsets in bytes and hexadecimal values 2018-04-30 17:11:40 +02:00
test9-fn-changed-v0.cc Fix synthesizing of reference type 2016-02-04 11:26:22 +01:00
test9-fn-changed-v0.h Fix synthesizing of reference type 2016-02-04 11:26:22 +01:00
test9-fn-changed-v1.cc Fix synthesizing of reference type 2016-02-04 11:26:22 +01:00
test9-fn-changed-v1.h Fix synthesizing of reference type 2016-02-04 11:26:22 +01:00