mirror of
git://sourceware.org/git/libabigail.git
synced 2024-12-15 22:44:41 +00:00
2638a26360
When referring to an anonymous struct or union, libabigail used to name it __anonymous_struct__ or __anonymous_union__. Now, with this patch, libabigail rather uses the flat representation of the struct/union, e.g, struct {int foo; char bar;}. * src/abg-ir.cc (get_class_or_union_flat_representation): Take a const class_or_union* (like what the declaration in the header file says), rather than just a class_or_union*. ({class,union}_decl::get_pretty_representation): For anonymous classes and unions, use the flat representation. * tests/data/test-annotate/libtest23.so.abi: Adjust. * tests/data/test-annotate/libtest24-drop-fns-2.so.abi: Likewise. * tests/data/test-annotate/libtest24-drop-fns.so.abi: Likewise. * tests/data/test-annotate/test13-pr18894.so.abi: Likewise. * tests/data/test-annotate/test14-pr18893.so.abi: Likewise. * tests/data/test-annotate/test15-pr18892.so.abi: Likewise. * tests/data/test-annotate/test17-pr19027.so.abi: Likewise. * tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi: Likewise. * tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi: Likewise. * tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi: Likewise. * tests/data/test-annotate/test21-pr19092.so.abi: Likewise. * tests/data/test-diff-dwarf/test43-PR22913-report-0.txt: Likewise. * tests/data/test-diff-dwarf/test44-anon-struct-union-report-0.txt: New test reference output. * tests/data/test-diff-dwarf/test44-anon-struct-union-v{0,1}.cc: Source code of new test binary outputs. * tests/data/test-diff-dwarf/test44-anon-struct-union-v{0,1}.o: New test binary outputs. * tests/data/Makefile.am: Add the new test materials above to source districution. * tests/test-diff-dwarf.cc (in_out_specs): Add the new test material above to the test harness here. * tests/data/test-diff-filter/test30-pr18904-rvalueref-report0.txt: Adjust. * 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/test35-pr18754-no-added-syms-report-0.txt: Likewise. * tests/data/test-diff-pkg/libcdio-0.94-1.fc26.x86_64--libcdio-0.94-2.fc26.x86_64-report.1.txt: Likewise. * tests/data/test-diff-pkg/spice-server-0.12.4-19.el7.x86_64-0.12.8-1.el7.x86_64-report-2.txt: Likewise. * tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi: Likewise. Signed-off-by: Dodji Seketeli <dodji@redhat.com>
21 lines
386 B
C++
21 lines
386 B
C++
//
|
|
// To compile this file, type:
|
|
//
|
|
// g++ -c -g test44-anon-struct-union-v1.cc
|
|
//
|
|
//
|
|
// This test modifies the type of the S0::m0 data member from the
|
|
// anonymous union to a native type. The resulting change report must
|
|
// refer to the anonymous union by using its flat representation,
|
|
// rather than just "__anonymous_union__".
|
|
|
|
struct S0
|
|
{
|
|
int m0;
|
|
int m1;
|
|
};
|
|
|
|
void
|
|
foo(S0*)
|
|
{}
|