mirror of
https://github.com/php/php-src.git
synced 2024-12-14 20:33:36 +08:00
19 lines
283 B
PHP
19 lines
283 B
PHP
--TEST--
|
|
Leak when using an invalid parent:: reference in a constant definition
|
|
--FILE--
|
|
<?php
|
|
|
|
class A {
|
|
const B = parent::C;
|
|
}
|
|
|
|
try {
|
|
A::B;
|
|
} catch (Error $e) {
|
|
echo $e->getMessage(), "\n";
|
|
}
|
|
|
|
?>
|
|
--EXPECT--
|
|
Cannot access parent:: when current class scope has no parent
|