xref: /PHP-5.3/Zend/tests/magic_by_ref_001.phpt (revision 90d58d46)
1--TEST--
2passing first parameter of __set() by ref
3--FILE--
4<?php
5
6class test {
7    function __set(&$name, $val) { }
8}
9
10$t = new test;
11$name = "prop";
12$t->$name = 1;
13
14echo "Done\n";
15?>
16--EXPECTF--
17Fatal error: Method test::__set() cannot take arguments by reference in %s on line %d
18