[RFA] Change program_space::added_solibs to a std::vector

Simon Marchi simon.marchi@ericsson.com
Tue May 29 16:14:00 GMT 2018


On 2018-05-29 11:11 AM, Tom Tromey wrote:
> This changes program_space::added_solibs to a std::vector, removing a
> VEC.
> 
> Tested by the buildbot.
> 
> ChangeLog
> 2018-05-29  Tom Tromey  <tom@tromey.com>
> 
> 	* progspace.h (so_list_ptr): Remove typedef.  Don't declare VEC.
> 	(struct program_space) <added_solibs>: Now a std::vector.
> 	* breakpoint.c (print_solib_event): Update.
> 	(check_status_catch_solib): Update.
> 	* progspace.c (clear_program_space_solib_cache): Update.
> 	* solib.c (update_solib_list): Update.
> ---
>  gdb/ChangeLog    |  9 +++++++++
>  gdb/breakpoint.c | 22 ++++++----------------
>  gdb/progspace.c  |  3 +--
>  gdb/progspace.h  |  5 +----
>  gdb/solib.c      |  2 +-
>  5 files changed, 18 insertions(+), 23 deletions(-)
> 
> diff --git a/gdb/breakpoint.c b/gdb/breakpoint.c
> index 721afd2c049..291442a6b55 100644
> --- a/gdb/breakpoint.c
> +++ b/gdb/breakpoint.c
> @@ -4580,8 +4580,7 @@ static void
>  print_solib_event (int is_catchpoint)
>  {
>    bool any_deleted = !current_program_space->deleted_solibs.empty ();
> -  int any_added
> -    = !VEC_empty (so_list_ptr, current_program_space->added_solibs);
> +  int any_added = !current_program_space->added_solibs.empty ();

bool?

Otherwise LGTM.

Thanks,

Simon



More information about the Gdb-patches mailing list