php-src/Zend/tests/const_array_with_resource_key.phpt
2016-09-28 23:22:11 +02:00

16 lines
251 B
PHP

--TEST--
Constexpr arrays should be able to handle resource keys
--FILE--
<?php
const FOO = [STDIN => 42];
var_dump(FOO);
?>
--EXPECTF--
Notice: Resource ID#%d used as offset, casting to integer (%d) in %s on line %d
array(1) {
[%d]=>
int(42)
}