This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [PATCH] Convert target_structs vector to VEC
- From: Simon Marchi <simon dot marchi at ericsson dot com>
- To: <gdb-patches at sourceware dot org>
- Date: Tue, 19 Aug 2014 11:39:33 -0400
- Subject: Re: [PATCH] Convert target_structs vector to VEC
- Authentication-results: sourceware.org; auth=none
- References: <1408134874-15078-1-git-send-email-simon dot marchi at ericsson dot com> <20140819064238 dot GC1773 at adacore dot com>
On 14-08-19 02:42 AM, Joel Brobecker wrote:
>> I thought that this home made implementation of a vector could be
>> replaced by the more standard VEC. The implementation seems to predate
>> the introduction of vec.h, so that would explain why it exists.
>>
>> Ran make check before and after, no new failures.
>>
>> gdb/ChangeLog:
>>
>> 2014-08-15 Simon Marchi <simon.marchi@ericsson.com>
>>
>> * target.c (target_struct_size): Remove.
>> (target_struct_allocsize): Remove.
>> (DEFAULT_ALLOCSIZE): Remove.
>> (target_ops_p): New typedef.
>> (DEF_VEC_P (target_ops_p)): New vector type.
>> (target_structs): Change type to VEC (target_ops_p).
>> (add_target_with_completer): Replace "push" code by VEC_safe_push.
>> (find_default_run_target): Rewrite for loop following changes to
>> target_structs.
>
> Nice! Please go ahead and push.
>
> Thank you,
>
Pushed, thanks!