php-src/Zend/tests/magic_by_ref_001.phpt
Steph Fox 6d8760677d - killed off UEXPECT
- altered EXPECT for parser errors. This may or may not be a Good Thing.
2008-05-26 14:33:44 +00:00

18 lines
283 B
PHP

--TEST--
passing first parameter of __set() by ref
--FILE--
<?php
class test {
function __set(&$name, $val) { }
}
$t = new test;
$name = "prop";
$t->$name = 1;
echo "Done\n";
?>
--EXPECTF--
Fatal error: Method test::__set() cannot take arguments by reference in %s on line %d