[wp-hackers] call time pass by reference (PHP 5.4 in-compatibilities)
Mike Schinkel
mike at newclarity.net
Fri Dec 28 23:52:32 UTC 2012
On Dec 28, 2012, at 6:43 PM, Andrew Nacin <wp at andrewnacin.com> wrote:
>> Would we consider adding a constant (with caveat[1]) that is halfway
>> between WP_DEBUG=true and WP_DEBUG=false? One that is set true for new
>> sites but false for upgraded sites, a WP_NO_DEPRECATED constant? This way
>> plugin authors would have most of an incentive to fix deprecated usage as
>> their plugins would fail for newer sites that don't allow deprecated usage
>>
>
> We simply have do_action_ref_array() pass all of its arguments to
> do_action()
> when WP_DEBUG is on, which would thus trigger E_WARNINGs in the situation
> I described and could then be dealt with. It'd be a good start.
Understood. I was hoping for a solution to nudge all the developers who do not use WP_DEBUG because they forget[1] or worse are (initially) not willing to[2] unless many people tell them otherwise.
I don't know how many there are that fit in category [2] but in my limited experience using other's plugins at least 1-in-3 fit in category [1].
-Mike
[1] http://wordpress.org/support/topic/undefined-index-hammy_parent-on-lin-55
[2] http://wordpress.org/support/topic/errors-when-using-wp_debug
More information about the wp-hackers
mailing list