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
10 files changed