forked from Imagelibrary/binutils-gdb
gdb: use gdb::function_view for gdbarch_iterate_over_objfiles_in_search_order callback
A rather straightforward patch to change an instance of callback + void pointer to gdb::function_view, allowing pasing lambdas that capture, and eliminating the need for the untyped pointer. Change-Id: I73ed644e7849945265a2c763f79f5456695b0037
This commit is contained in:
committed by
Simon Marchi
parent
1653ae5b84
commit
6e9cd73eb5
@@ -78,8 +78,8 @@ extern struct gdbarch *target_gdbarch (void);
|
||||
/* Callback type for the 'iterate_over_objfiles_in_search_order'
|
||||
gdbarch method. */
|
||||
|
||||
typedef int (iterate_over_objfiles_in_search_order_cb_ftype)
|
||||
(struct objfile *objfile, void *cb_data);
|
||||
using iterate_over_objfiles_in_search_order_cb_ftype
|
||||
= gdb::function_view<bool(objfile *)>;
|
||||
|
||||
/* Callback type for regset section iterators. The callback usually
|
||||
invokes the REGSET's supply or collect method, to which it must
|
||||
|
||||
Reference in New Issue
Block a user