[webkit-reviews] review granted: [Bug 203197] Web Inspector: make ObjC protocol dispatcher commands optional and add `respondsToSelector` checks to allow other inspector clients to choose what they implement : [Attachment 381438] Patch

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Mon Oct 21 13:37:53 PDT 2019


Joseph Pecoraro <joepeck at webkit.org> has granted Devin Rousso
<drousso at apple.com>'s request for review:
Bug 203197: Web Inspector: make ObjC protocol dispatcher commands optional and
add `respondsToSelector` checks to allow other inspector clients to choose what
they implement
https://bugs.webkit.org/show_bug.cgi?id=203197

Attachment 381438: Patch

https://bugs.webkit.org/attachment.cgi?id=381438&action=review




--- Comment #3 from Joseph Pecoraro <joepeck at webkit.org> ---
Comment on attachment 381438
  --> https://bugs.webkit.org/attachment.cgi?id=381438
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=381438&action=review

r=me!

>
Source/JavaScriptCore/inspector/scripts/codegen/generate_objc_backend_dispatche
r_implementation.py:110
> +    def _generate_responds_to_selector_for_command(self, domain, command):
> +	   return '[m_delegate
respondsToSelector:@selector(%sWithErrorCallback:successCallback:%s)]' %
(command.command_name, ''.join(map(lambda parameter: '%s:' %
parameter.parameter_name, command.call_parameters)))

You can probably just simplify this to join parameters with a colon, and add
the trailing colon to the respondsToSelector part of the format string.


More information about the webkit-reviews mailing list