[webkit-reviews] review requested: [Bug 210336] check-webkit-style should warn about 'decode' functions with missing WARN_UNUSED_RETURN attribute : [Attachment 396088] Patch v1

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Fri Apr 10 09:07:21 PDT 2020


Jonathan Bedard <jbedard at apple.com> has asked  for review:
Bug 210336: check-webkit-style should warn about 'decode' functions with
missing WARN_UNUSED_RETURN attribute
https://bugs.webkit.org/show_bug.cgi?id=210336

Attachment 396088: Patch v1

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




--- Comment #4 from Jonathan Bedard <jbedard at apple.com> ---
Comment on attachment 396088
  --> https://bugs.webkit.org/attachment.cgi?id=396088
Patch v1

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

> Tools/Scripts/webkitpy/style/checkers/cpp.py:1818
> +	       if function_state.has_return_type('(auto|bool|Optional<.+>)'):

I would actually expect this to be an inverse check. If a function does not
have a void return type, then we should trigger this logic. Any reason we
picked this set of types?


More information about the webkit-reviews mailing list