php-src/Zend/tests/class_on_constant_evaluated_expression.phpt
2020-07-10 21:05:28 +02:00

11 lines
210 B
PHP

--TEST--
An error should be generated when using ::class on a constant evaluated expression
--FILE--
<?php
(1+1)::class;
?>
--EXPECTF--
Fatal error: Cannot use "::class" on value of type int in %s on line %d