Plugins: Improve hook performance by using `spl_object_id()` instead of `spl_object_hash()` to construct unique IDs.
* Also use `spl_object_id()` similarly when registering and unregistering classic widgets. * Improve typing and phpdoc in `_wp_filter_build_unique_id()`. Return `null` for malformed callbacks. * Add tests for `_wp_filter_build_unique_id()`. * Improve type safety of `WP_Hook::add_filter()` in case an invalid callback is provided for parity with `::has_filter()` and `::remove_filter()`. Developed in https://github.com/WordPress/wordpress-develop/pull/11865 Follow-up to r46220, r46801, r60179. Props bor0, westonruter, SergeyBiryukov, schlessera, arshidkv12, knutsp, spacedmonkey, swissspidy. See #64898. Fixes #58291. git-svn-id: https://develop.svn.wordpress.org/trunk@62408 602fd350-edb4-49c9-b593-d223f7449a82
W
Weston Ruter committed
956081111b451bf312be89665d643387f9cd48ac
Parent: 4e28109