mirror of
https://github.com/php/php-src.git
synced 2026-03-24 00:02:20 +01:00
Instead of always saying that a name is reserved or deprecated and cannot/should not be used as a class name, take the usage into account and say the name cannot be used as an enum name, trait name, etc. In the process, for class names add a missing "a".
13 lines
199 B
PHP
13 lines
199 B
PHP
--TEST--
|
|
errmsg: cannot use 'parent' as class name
|
|
--FILE--
|
|
<?php
|
|
|
|
class parent {
|
|
}
|
|
|
|
echo "Done\n";
|
|
?>
|
|
--EXPECTF--
|
|
Fatal error: Cannot use 'parent' as a class name as it is reserved in %s on line %d
|