php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Doc Bug #49117 ambiguous documentation
Submitted: 2009-07-31 06:19 UTC Modified: 2009-08-05 11:10 UTC
Votes:1
Avg. Score:3.0 ± 0.0
Reproduced:1 of 1 (100.0%)
Same Version:0 (0.0%)
Same OS:1 (100.0%)
From: ben dot zayb at yahoo dot com Assigned:
Status: Closed Package: Documentation problem
PHP Version: Irrelevant OS:
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: ben dot zayb at yahoo dot com
New email:
PHP Version: OS:

 

 [2009-07-31 06:19 UTC] ben dot zayb at yahoo dot com
Description:
------------
"The behaviour of functions with by-reference parameters called by value has changed. Where previously the function would accept the by-value argument, a warning is now emitted and all by-ref parameters are set to NULL."

I find this ambiguous/difficult to understand.

"The behaviour of functions with by-reference parameters..."

Ok. This is a function "with by-reference parameters..."

<?php
function a( &$param ){
}
?>

"..called by value has changed. Where previously the function would accept the by-value argument"

Ok. This is "would accept the by-value argument..."
<?php
a(2); //2 is a literal
?>
But this is illegal even in 5.2.

So, I suppose this what is meant by "..called by value..."
<?php
a($someVariable);
?>

"a warning is now emitted and all by-ref parameters are set to NULL"

So, this would cause a warning, and all by-ref paramaters are set to NULL?

Thanks


Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2009-08-04 07:15 UTC] initcontact at grahamwideman dot com
I agree. This note is very ambiguous -- needs an example.
BTW, here's the page URL:
http://us2.php.net/manual/en/migration53.incompatible.php
 [2009-08-05 11:10 UTC] svn@php.net
Automatic comment from SVN on behalf of bjori
Revision: http://svn.php.net/viewvc/?view=revision&revision=286830
Log: - Fixed bug#49117 (ambiguous documentation) (Patch by Niel Archer)
- Added note about mysqlnd not reading my.cnf/my.ini (Patch by Niel Archer)
 [2009-08-05 11:10 UTC] bjori@php.net
This bug has been fixed in the documentation's XML sources. Since the
online and downloadable versions of the documentation need some time
to get updated, we would like to ask you to be a bit patient.

Thank you for the report, and for helping us make our documentation better.


 
PHP Copyright © 2001-2025 The PHP Group
All rights reserved.
Last updated: Thu Jul 10 10:01:32 2025 UTC