Libabigail's DWARF reader does not support the DW_AT_count attribute
used to specify the number of elements in an array subrange. Rather,
it uses the DW_AT_lower_bound and DW_AT_upper_bound attributes that
are emitted by GCC. Recent versions of Clang, on the other hand, use
the DW_AT_count attribute.
This patch adds support for the DW_AT_count attribute too.
* src/abg-dwarf-reader.cc (get_default_array_lower_bound): Define
new static function.
(build_array_type): Support the DW_AT_count attribute.
* tests/data/test-diff-dwarf/test35-pr19173-libfoo-long-clang.so:
New test binary input.
* tests/data/test-diff-dwarf/test35-pr19173-libfoo-long-clang2.so: Likewise.
* tests/data/test-diff-dwarf/test35-pr19173-libfoo-long-clang-report-0.txt:
New test reference output.
* tests/data/test-diff-dwarf/test35-pr19173-libfoo-long-gcc.so:
New test binary input.
* tests/data/test-diff-dwarf/test35-pr19173-libfoo-long-gcc2.so:
New test binary input.
* tests/data/test-diff-dwarf/test35-pr19173-libfoo-long-gcc-report-0.txt:
New test reference output.
* tests/data/test-diff-dwarf/test35-pr19173-libfoo-long.c: Source
code for the binaries above.
* tests/data/Makefile.am: Add the new test material to the build
system.
* tests/test-diff-dwarf.cc (in_out_specs): Add the new test inputs
to the harness.
Signed-off-by: Dodji Seketeli <dodji@redhat.com>