mirror of
https://github.com/php/php-src.git
synced 2024-09-23 02:47:26 +00:00
16a9bc1ec2
Also fix a bug with return types where "self" was rejected inside a class, but not on a method. Fallout: A couple of tests changed to more generic error messages.
11 lines
222 B
PHP
11 lines
222 B
PHP
--TEST--
|
|
class name as scalar from ::class keyword error using parent in non class context
|
|
--FILE--
|
|
<?php
|
|
|
|
$x = parent::class;
|
|
|
|
?>
|
|
--EXPECTF--
|
|
Fatal error: Cannot use "parent" when no class scope is active in %s on line 3
|