Skip to content
Find file
Fetching contributors…
Cannot retrieve contributors at this time
31 lines (30 sloc) 940 Bytes
Test for bug #328: Private properties are incorrectly enumerated in case of extended classes
class Daddy
private $bar = 42;
protected $pro = 242;
public $pub = 342;
class Inherit extends Daddy
private $bar = 43;
protected $pro = 243;
public $pub = 343;
$a = new Inherit;
var_dump( $a );
<pre class='xdebug-var-dump' dir='ltr'>
<i>private</i> 'bar' <font color='#888a85'>=&gt;</font> <small>int</small> <font color='#4e9a06'>43</font>
<i>protected</i> 'pro' <font color='#888a85'>=&gt;</font> <small>int</small> <font color='#4e9a06'>243</font>
<i>public</i> 'pub' <font color='#888a85'>=&gt;</font> <small>int</small> <font color='#4e9a06'>343</font>
<i>private</i> 'bar' <small>(Daddy)</small> <font color='#888a85'>=&gt;</font> <small>int</small> <font color='#4e9a06'>42</font>
Jump to Line
Something went wrong with that request. Please try again.