PR23641 - confusion when a type definition DIE is matched by a supprspec and its decl DIEs aren't
This is a followup of the patch with commit hash
90b4e76.
It turns out that in some cases, when we see a suppressed private
class definition, we haven't *previously* seen any declaration-only
instance of it. So we cannot use any pre-existing declaration-only
instance as an opaque type for the private type that is suppressed.
In that case, this patch creates (and uses) a declaration-only
instance for the suppressed private type definition.
* src/abg-dwarf-reader.cc (get_opaque_version_of_type): If no
pre-existing opaque version was found, a new one is created and
returned. Take a needed "where_offset" parameter.
(build_ir_node_from_die): Adjust the call to
get_opaque_version_of_type.
Signed-off-by: Dodji Seketeli <dodji@redhat.com>