Fix internal name for pointers, typedefs and arrays
Internal names (and pretty representation) of types are used for type
canonicalization. These were not being correctly computed for
pointers typedefs and arrays because we were forgetting sometimes to
use internal names of the underlying types, especially because of caching issues.
This patch addresses that.
Note that I noticed this while comparing the two versions of
libgromacs_d.so.0.0.0 involved in the comparison referenced by bug
https://bugzilla.redhat.com/show_bug.cgi?id=1283906. But then that
library is too big (and takes too much time) to be included as a non
regression test :(
* include/abg-ir.h (pointer_type_def::priv_): New data structure.
The type is now pimpled.
(typedef_decl::priv_): Likewise.
* src/abg-ir.cc (struct pointer_type_def::priv): New struct.
(pointer_type_def::pointer_type_def): Adjust.
(pointer_type_def::get_pointed_to_type): Likewise.
(pointer_type_def::get_qualified_name): Store temporary/internal
names into different caches.
(array_type_def::priv::{temp_internal_qualified_name_,
internal_qualified_name_}): New data members.
(get_type_representation): In the overload for array_type_def,
take requests for internal names into account.
(array_type_def::get_qualified_name): Take requests for internal
names into account. Store temporary/internal names into different
caches.
(typedef_decl::priv): New struct.
(typedef_decl::typedef_decl): Adjust.
(typedef_decl::get_underlying_type): Likewise.
Signed-off-by: Dodji Seketeli <dodji@redhat.com>