|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2018-04-05 15:01 UTC] requinix@php.net
-Status: Open
+Status: Not a bug
[2018-04-05 15:01 UTC] requinix@php.net
[2018-04-25 02:22 UTC] a at b dot c dot de
[2018-04-25 02:43 UTC] requinix@php.net
[2018-07-29 05:13 UTC] a at b dot c dot de
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Sat Dec 20 05:00:01 2025 UTC |
Description: ------------ Notice is falsely triggered. The two examples should be the same. Test script: --------------- <?php ini_set("display_errors", 1); error_reporting(E_ALL); // Function with reference parameter function fn (&$obj) {} fn($obj = new stdClass()); // <- Triggers notice: Only variables should be passed by reference // ... should be the same as ... $obj = new stdClass(); fn($obj); // <- No warning Expected result: ---------------- No notice Actual result: -------------- Notice: Only variables should be passed by reference in xxx