mirror of
https://github.com/php/php-src.git
synced 2026-03-24 08:12:21 +01:00
Remove support for custom assert() function
Deprecated in PHP 7.3 as part of https://wiki.php.net/rfc/deprecations_php_7_3.
This commit is contained in:
@@ -9,4 +9,4 @@ function assert() {}
|
||||
|
||||
?>
|
||||
--EXPECTF--
|
||||
Deprecated: Defining a custom assert() function is deprecated, as the function has special semantics in %s on line %d
|
||||
Fatal error: Defining a custom assert() function is not allowed, as the function has special semantics in %s on line %d
|
||||
@@ -5740,8 +5740,8 @@ static void zend_begin_func_decl(znode *result, zend_op_array *op_array, zend_as
|
||||
}
|
||||
|
||||
if (zend_string_equals_literal_ci(unqualified_name, "assert")) {
|
||||
zend_error(E_DEPRECATED,
|
||||
"Defining a custom assert() function is deprecated, "
|
||||
zend_error(E_COMPILE_ERROR,
|
||||
"Defining a custom assert() function is not allowed, "
|
||||
"as the function has special semantics");
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user