Doc #65699 [Opn]: Problem in comment section for end() documentation
| From: | joem at numberfour dot eu | Date: | Wed, 18 Sep 2013 16:58:41 +0000 |
| Subject: | Doc #65699 [Opn]: Problem in comment section for end() documentation | ||
| References: | 1 | Groups: | php.doc.bugs |
| Request: | Send a blank email to doc-bugs+get-10269@lists.php.net to get a copy of this message | ||
Edit report at https://bugs.php.net/bug.php?id=65699&edit=1
ID: 65699
User updated by: joem at numberfour dot eu
Reported by: joem at numberfour dot eu
Summary: Problem in comment section for end() documentation
Status: Open
Type: Documentation Problem
Package: *General Issues
PHP Version: Irrelevant
Block user comment: N
Private report: N
New Comment:
Right, however the comment instructions say not to refer to other comments. They
also ask to file a bug if there are any problems. That comment clearly will lead
some people down a buggy path and so should be corrected/deleted/added to.
What is the correct thing to do when you see comments with bad information?
Previous Comments:
------------------------------------------------------------------------
[2013-09-18 16:55:00] gabri dot ns at gmail dot com
first off all, comment section is not part off documentation.
its just a means for user to share knowledge. if its usefull,
it is possible to include it to the documentation.
secondly, don't trust any off code in it, since it maybe coded
in different environtment with yours. try it yourself...
if it work, take it. if don't, leave it. or may be you can read
the documentation to find the problem with the code, yourself.
don't report it here. if you need help, open http://www.php.net/support.php
and join one of available option there.
lastly, try open http://www.php.net/references and
http://www.php.net/array_pop to find the source of evil
from the code.
regard,
gabri
------------------------------------------------------------------------
[2013-09-18 16:26:30] joem at numberfour dot eu
Description:
------------
---
From manual page: http://www.php.net/function.end
---
In comment
this line: $lastkey = array_pop(array_keys($arr));
Would result in:
Strict standards: Only variables should be passed by reference in php shell code
on line 1
------------------------------------------------------------------------
--
Edit this bug report at https://bugs.php.net/bug.php?id=65699&edit=1