Make target_desc::compatible an std::vector
authorSimon Marchi <simon.marchi@polymtl.ca>
Tue, 5 Dec 2017 21:30:22 +0000 (16:30 -0500)
committerSimon Marchi <simon.marchi@ericsson.com>
Tue, 5 Dec 2017 21:30:22 +0000 (16:30 -0500)
commit40e2a9835f6cf47b630babef3fd788e413ef2dc5
treecf01d725ca8a3ccc709d387e8b545849790010bd
parent129c10bcb9b3bc2ed9682040aa9a0d144bb5e959
Make target_desc::compatible an std::vector

This patch changes target_desc::compatible to be a vector of
bfd_arch_info *.  This way, we don't need to manually free the vector in
the target_desc destructor.

gdb/ChangeLog:

* target-descriptions.c (arch_p): Remove typedef.
(DEF_VEC_P (arch_p)): Remove.
(struct target_desc) <compatible>: Change type to std::vector.
<~target_desc>: Don't manually free compatible.
(tdesc_compatible_p): Adjust.
(tdesc_add_compatible): Adjust.
(class print_c_tdesc) <visit_pre>: Adjust.
gdb/ChangeLog
gdb/target-descriptions.c