[PATCH v4 3/9] add target method delegation
Tom Tromey
tromey@redhat.com
Wed Dec 11 22:03:00 GMT 2013
>>>>> "Pedro" == Pedro Alves <palves@redhat.com> writes:
Pedro> So to take that example, if we made dummy_target.to_wait be the
Pedro> current to_wait default, which is to call noprocess(), then
Pedro> it'd be clear that target_delegate_wait shouldn't ever go past
Pedro> the loop, and then it'd be clear that an assertion is appropriate.
Pedro> target_wait would then be:
[...]
Pedro> WDYT?
It seems good to me.
I'll make a patch to normalize the delegation across all the target
methods. Too bad for me I already touched all these methods on the
multi-target branch -- ouch.
Testing revealed that we can't put the assert into
target_delegate_async. This is a funny one. The dummy target has:
dummy_target.to_can_async_p = find_default_can_async_p;
... but this means that it is possible for to_can_async_p to return true
while the target does not actually implement to_async.
Tom
More information about the Gdb-patches
mailing list