Hi all,
I just noticed (don't ask) there are a couple of checks in
zend_do_pass_param() in CVS HEAD that don't exist in PHP_5_3:
if (original_op==ZEND_SEND_REF) {
if (function_ptr &&
function_ptr->common.function_name.v &&
function_ptr->common.type == ZEND_USER_FUNCTION &&
!ARG_SHOULD_BE_SENT_BY_REF(function_ptr, (zend_uint) offset)) {
zend_error(E_DEPRECATED,
"Call-time pass-by-reference has been deprecated; "...
Is there any chance of back-porting the common.type check to 5_3?
- Steph
That wasn't very clear, sorry...
The logic in HEAD gives nice, sane warnings. The logic in 5_3 gives the same
warning for everything, e.g:
Deprecated: Call-time pass-by-reference has been deprecated; If you would
like to pass it by reference, modify the declaration of call_user_func()
...
It just doesn't make a lot of sense to keep a warning that tells users to
modify the declaration of internal functions, IMHO.
- Steph
----- Original Message -----
From: "Steph Fox" steph@phparch.com
To: "internals" internals@lists.php.net
Cc: "Dmitry Stogov" dmitry@zend.com; "Johannes Schlueter"
johannes@schlueters.de
Sent: Sunday, June 15, 2008 1:51 PM
Subject: [PHP-DEV] Back to call_time_pass_reference - backport PHP 6
behaviour?
Hi all,
I just noticed (don't ask) there are a couple of checks in
zend_do_pass_param() in CVS HEAD that don't exist in PHP_5_3:if (original_op==ZEND_SEND_REF) {
if (function_ptr &&
function_ptr->common.function_name.v &&
function_ptr->common.type == ZEND_USER_FUNCTION &&
!ARG_SHOULD_BE_SENT_BY_REF(function_ptr, (zend_uint) offset)) {
zend_error(E_DEPRECATED,
"Call-time pass-by-reference has been deprecated; "...Is there any chance of back-porting the common.type check to 5_3?
- Steph
Hi
Em Dom, 2008-06-15 às 14:10 +0100, Steph Fox escreveu:
That wasn't very clear, sorry...
The logic in HEAD gives nice, sane warnings. The logic in 5_3 gives the same
warning for everything, e.g:Deprecated: Call-time pass-by-reference has been deprecated; If you would
like to pass it by reference, modify the declaration ofcall_user_func()
...It just doesn't make a lot of sense to keep a warning that tells users to
modify the declaration of internal functions, IMHO.
Indeed.
Backported to 5_3 and 5_2.
--
Regards,
Felipe Pena.