code quality: add explicit : void to method signatures in wp-signup.php, WP_Posts_List_Table, and WP_Screen#8965
Conversation
|
The following accounts have interacted with this PR and/or linked issues. I will continue to update these lists as activity occurs. You can also manually ask me to refresh this list by adding the Core Committers: Use this line as a base for the props when committing in SVN: To understand the WordPress project's expectations around crediting contributors, please review the Contributor Attribution page in the Core Handbook. |
Test using WordPress PlaygroundThe changes in this pull request can previewed and tested using a WordPress Playground instance. WordPress Playground is an experimental project that creates a full WordPress instance entirely within the browser. Some things to be aware of
For more details about these limitations and more, check out the Limitations page in the WordPress Playground documentation. |
….php, WP_Posts_List_Table, and WP_Screen
b6f10b5 to
e8a81e7
Compare
This comment was marked as off-topic.
This comment was marked as off-topic.
|
@westonruter should this have been closed by the phpstan level 0 commit? |
|
No! 😢 |
Specifically for set_screen_reader_content() and remove_screen_reader_content(). Co-authored-by: gemini-cli <176961590+gemini-code-assist[bot]@users.noreply.github.com>
This PR updates the method signatures of several functions and files to enforce a
: voidreturn type. Changes are non-breaking and unlikely to disrupt other open PRs.More specifically:
finalclass (cant be extended)While surfaced and part of PHPStan efforts (https://core.trac.wordpress.org/ticket/61175 / #7619 ), this PR serves as proof of concept for a larger proposal that would see
: voidreturn types implemented across the codebase in a nondisruptive manner while lay the groundwork for safely implementing other return types to existing method signatures.Trac ticket: https://core.trac.wordpress.org/ticket/63558
This Pull Request is for code review only. Please keep all other discussion in the Trac ticket. Do not merge this Pull Request. See GitHub Pull Requests for Code Review in the Core Handbook for more details.