mirror of
https://github.com/php/php-src.git
synced 2025-08-18 15:08:55 +02:00
15 lines
320 B
PHP
15 lines
320 B
PHP
--TEST--
|
|
Self-referencing constant expression (part of a constant AST)
|
|
--XFAIL--
|
|
Not yet fixed, to be fixed for PHP 5.6
|
|
--FILE--
|
|
<?php
|
|
class A {
|
|
const FOO = [self::BAR];
|
|
const BAR = [self::FOO];
|
|
}
|
|
var_dump(A::FOO);
|
|
?>
|
|
--EXPECTF--
|
|
Fatal error: Cannot declare self-referencing constant 'self::FOO' in %s on line %d
|
|
|