mirror of
git://sourceware.org/git/libabigail.git
synced 2025-01-31 05:41:38 +00:00
a16b922b11
This issue was reported in bug https://sourceware.org/bugzilla/show_bug.cgi?id=27700. When we construct an opaque type (triggered by the use of --drop-private-types along with the --headers-dir option on abidw, for instance) with get_opaque_version_of_type we forget to canonicalize the resulting type. Later, at abixml emitting time (for instance) hash_as_canonical_type_or_constant would rightfully abort because the type wasn't canonicalized. We want all types (okay, modulo one exception) in the system to be canonicalized. This patch fixes the problem by canonicalizing opaque types. * src/abg-dwarf-reader.cc (build_ir_node_from_die): Canonicalize opaque enums and classes. * tests/data/test-read-dwarf/PR27700/include-dir/priv.h: New test header file. * tests/data/test-read-dwarf/PR27700/include-dir/pub.h: Likewise * tests/data/test-read-dwarf/PR27700/pub-incdir/inc.h: Likewise. * tests/data/test-read-dwarf/PR27700/test-PR27700.o: New binary input file. * tests/data/test-read-dwarf/PR27700/test-PR27700.abi: Reference abi file of the binary above. * tests/data/test-read-dwarf/PR27700/test-PR27700.c: Source file of the binary above. * tests/data/Makefile.am: Add the test material above to source distribution. * tests/test-read-dwarf.cc (InOutSpec::in_public_headers_path): Add new data member. (in_out_specs): Adjust to reflect the new data member in the InOutSpec type. Add a new test input. (set_suppressions_from_headers): Define new static function. (test_task::perform): Use the content of the new InOutSpec::in_public_headers_path to construct and add "--headers-dir <headers-dir> --drop-private-types" to the options of the abidw program run. Signed-off-by: Dodji Seketeli <dodji@redhat.com> |
||
---|---|---|
.. | ||
data | ||
lib | ||
.gitignore | ||
Makefile.am | ||
mockfedabipkgdiff.in | ||
print-diff-tree.cc | ||
runtestcanonicalizetypes.sh.in | ||
runtestdefaultsupprs.py.in | ||
runtestdefaultsupprspy3.sh.in | ||
runtestfedabipkgdiff.py.in | ||
runtestfedabipkgdiffpy3.sh.in | ||
runtestslowselfcompare.sh.in | ||
test-abicompat.cc | ||
test-abidiff-exit.cc | ||
test-abidiff.cc | ||
test-alt-dwarf-file.cc | ||
test-annotate.cc | ||
test-core-diff.cc | ||
test-cxx-compat.cc | ||
test-diff2.cc | ||
test-diff-dwarf-abixml.cc | ||
test-diff-dwarf.cc | ||
test-diff-filter.cc | ||
test-diff-pkg.cc | ||
test-diff-suppr.cc | ||
test-dot.cc | ||
test-elf-helpers.cc | ||
test-ini.cc | ||
test-ir-walker.cc | ||
test-kmi-whitelist.cc | ||
test-lookup-syms.cc | ||
test-read-dwarf.cc | ||
test-read-write.cc | ||
test-svg.cc | ||
test-symtab-reader.cc | ||
test-symtab.cc | ||
test-tools-utils.cc | ||
test-types-stability.cc | ||
test-utils.cc | ||
test-utils.h | ||
test-valgrind-suppressions.supp | ||
update-test-output.py |