2014-04-11 08:06:17 +00:00
|
|
|
--TEST--
|
|
|
|
Bug #66015 (wrong array indexing in class's static property)
|
|
|
|
--FILE--
|
|
|
|
<?php
|
|
|
|
class Test
|
|
|
|
{
|
|
|
|
const FIRST = 1;
|
|
|
|
const SECOND = 2;
|
|
|
|
const THIRD = 3;
|
|
|
|
|
|
|
|
protected static $array = [
|
|
|
|
self::FIRST => 'first',
|
|
|
|
'second',
|
2014-05-07 11:03:56 +00:00
|
|
|
'third',
|
|
|
|
4,
|
2014-04-11 08:06:17 +00:00
|
|
|
];
|
|
|
|
|
|
|
|
public function __construct()
|
|
|
|
{
|
|
|
|
var_export(self::$array);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
$test = new Test();
|
|
|
|
?>
|
2014-05-07 11:03:56 +00:00
|
|
|
|
|
|
|
===DONE===
|
2014-04-11 08:06:17 +00:00
|
|
|
--EXPECTF--
|
|
|
|
array (
|
|
|
|
1 => 'first',
|
|
|
|
2 => 'second',
|
|
|
|
3 => 'third',
|
2014-05-07 11:03:56 +00:00
|
|
|
4 => 4,
|
2014-04-11 08:06:17 +00:00
|
|
|
)
|
2014-05-07 11:03:56 +00:00
|
|
|
===DONE===
|