mirror of
https://github.com/php/php-src.git
synced 2024-11-23 18:04:36 +08:00
edf22962ef
We missed the change to make this an Error exception in PHP 8, but at least elevate it to a warning, to avoid a notice -> exception jump at a later time.
18 lines
211 B
PHP
18 lines
211 B
PHP
--TEST--
|
|
Defining constant twice with two different forms
|
|
--FILE--
|
|
<?php
|
|
|
|
define('a', 2);
|
|
const a = 1;
|
|
|
|
|
|
if (defined('a')) {
|
|
print a;
|
|
}
|
|
|
|
?>
|
|
--EXPECTF--
|
|
Warning: Constant a already defined in %s on line %d
|
|
2
|