mirror of
https://github.com/php/php-src.git
synced 2024-12-01 22:03:36 +08:00
25 lines
355 B
PHP
Executable File
25 lines
355 B
PHP
Executable File
--TEST--
|
|
Bug #24499 (bogus handling of a public property as a private one)
|
|
--FILE--
|
|
<?php
|
|
class Id {
|
|
private $id="priv";
|
|
|
|
public function tester($obj)
|
|
{
|
|
$obj->id = "bar";
|
|
}
|
|
}
|
|
|
|
$id = new Id();
|
|
@$obj->foo = "bar";
|
|
$id->tester($obj);
|
|
print_r($obj);
|
|
?>
|
|
--EXPECT--
|
|
stdClass Object
|
|
(
|
|
[foo] => bar
|
|
[id] => bar
|
|
)
|