Docs: Remove "private" designation from _doing_it_wrong() and related functions:

* `_deprecated_function()`
* `_deprecated_argument()`
* `_deprecated_constructor()`
* `_deprecated_file()`

Plugins and themes should be allowed to use these functions to throw appropriate error notices.

This brings them in line with newer `do_action_deprecated()` and `apply_filters_deprecated()` functions, which are not marked as private.

Props jrf.
Fixes #48251.
Built from https://develop.svn.wordpress.org/trunk@46602


git-svn-id: http://core.svn.wordpress.org/trunk@46399 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
Sergey Biryukov 2019-10-27 14:21:03 +00:00
parent e015fbd8bb
commit c283f8b1ed
2 changed files with 6 additions and 7 deletions

View File

@ -4547,7 +4547,7 @@ function absint( $maybeint ) {
* This function is to be used in every function that is deprecated.
*
* @since 2.5.0
* @access private
* @since 5.4.0 This function is no longer marked as "private".
*
* @param string $function The function that was called.
* @param string $version The version of WordPress that deprecated the function.
@ -4604,8 +4604,7 @@ function _deprecated_function( $function, $version, $replacement = null ) {
*
* @since 4.3.0
* @since 4.5.0 Added the `$parent_class` parameter.
*
* @access private
* @since 5.4.0 This function is no longer marked as "private".
*
* @param string $class The class containing the deprecated constructor.
* @param string $version The version of WordPress that deprecated the function.
@ -4697,7 +4696,7 @@ function _deprecated_constructor( $class, $version, $parent_class = '' ) {
* This function is to be used in every file that is deprecated.
*
* @since 2.5.0
* @access private
* @since 5.4.0 This function is no longer marked as "private".
*
* @param string $file The file that was included.
* @param string $version The version of WordPress that deprecated the file.
@ -4764,7 +4763,7 @@ function _deprecated_file( $file, $version, $replacement = null, $message = '' )
* The current behavior is to trigger a user error if WP_DEBUG is true.
*
* @since 3.0.0
* @access private
* @since 5.4.0 This function is no longer marked as "private".
*
* @param string $function The function that was called.
* @param string $version The version of WordPress that deprecated the argument used.
@ -4871,7 +4870,7 @@ function _deprecated_hook( $hook, $version, $replacement = null, $message = null
* The current behavior is to trigger a user error if `WP_DEBUG` is true.
*
* @since 3.1.0
* @access private
* @since 5.4.0 This function is no longer marked as "private".
*
* @param string $function The function that was called.
* @param string $message A message explaining what has been done incorrectly.

View File

@ -13,7 +13,7 @@
*
* @global string $wp_version
*/
$wp_version = '5.4-alpha-46601';
$wp_version = '5.4-alpha-46602';
/**
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.