|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
[2000-08-29 21:38 UTC] waldschrott@php.net
func_get_arg() does not support references (see example),
$o=1;
test($o);
echo $o;
function test() {
$l=&func_get_arg(0);
$l=2; }
displays 1, should 2, I think it should be possible changing this without impact, if not perhaps a func_get_rarg() be fine
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
|
|||||||||||||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Sat Oct 25 21:00:01 2025 UTC |
Stas: If I possible, I would like to better understand you statement...here is what I am thinking you mean, please correct me if I am wrong: $o=1; test($o); echo $o; function test() { $a = &func_get_args(); /** $a[0] has already been passed as a copy. We have no idea what to reference it back to! */ }