This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: RFC for: "Re: Regression for gdb.fortran/library-module.exp [Re: [RFA] choose symbol from given block's objfile first.]"


On 05/29/2012 05:11 PM, Jan Kratochvil wrote:

> It should be a pointer to function implementing the functionality - which
> differs across platforms:
> 
> M:void:iterate_over_objfiles_in_search_order: iterate_over_objfiles_in_search_order_cb cb, void *cb_data, struct objfile *context_objfile: cb, cb_data, context_objfile
>  - I did not check it should be very exactly this way like m vs. M etc.
> 
> default implementation:
>     static void
>     default_iterate_over_objfiles_in_search_order
>       (iterate_over_objfiles_in_search_order_cb cb,
>        void *cb_data,
>        struct objfile *context_objfile)
>     {
...


>     set_gdbarch_iterate_over_objfiles_in_search_order (gdbarch, default_iterate_over_objfiles_in_search_order);
> 
> 
> ms-windows implementation
> 
>     static void
>     windows_iterate_over_objfiles_in_search_order
>       (iterate_over_objfiles_in_search_order_cb cb,
>        void *cb_data,
>        struct objfile *context_objfile)
>     {

...

>     set_gdbarch_iterate_over_objfiles_in_search_order (gdbarch, windows_iterate_over_objfiles_in_search_order);
> 

Agreed.

(I'd suggest renaming context_objfile -> current_objfile, as that sounds to me closer
to what it really is used for, rather than a generic context, but that's a nit.)

-- 
Pedro Alves


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]