1--TEST-- 2Bug #23951 (Defines not working in inherited classes) 3--FILE-- 4<?php 5 6define('FOO1', 1); 7define('FOO2', 2); 8 9class A { 10 11 public $a_var = array(FOO1=>'foo1_value', FOO2=>'foo2_value'); 12 13} 14 15class B extends A { 16 17 public $b_var = 'foo'; 18 19} 20 21$a = new A; 22$b = new B; 23 24print_r($a); 25print_r($b->a_var); 26print_r($b->b_var); 27 28?> 29--EXPECT-- 30A Object 31( 32 [a_var] => Array 33 ( 34 [1] => foo1_value 35 [2] => foo2_value 36 ) 37 38) 39Array 40( 41 [1] => foo1_value 42 [2] => foo2_value 43) 44foo 45