[PHP-CVS] [php-src] master: Zend: Remove ZPP_ERROR_WRONG_COUNT case
[email protected] (Gina Peter Banyard) Mon, 3 Aug 2026 00:56:25 +0000
| Newsgroups | php.cvs |
|---|---|
| Message-ID | <[email protected]> |
Author: Gina Peter Banyard (Girgias)
Date: 2026-08-03T01:56:20+01:00
Commit: https://github.com/php/php-src/commit/bbf82d7a84c4fa10fd57ab438082e322758ba373
Raw diff: https://github.com/php/php-src/commit/bbf82d7a84c4fa10fd57ab438082e322758ba373.diff
Zend: Remove ZPP_ERROR_WRONG_COUNT case
As it is unused, the relevant error is handled before and _error_code is assigned ZPP_ERROR_FAILURE.
Changed paths:
M Zend/zend_API.c
M Zend/zend_API.h
Diff:
diff --git a/Zend/zend_API.c b/Zend/zend_API.c
index 84e7c8e1880e..758977e07d6a 100644
--- a/Zend/zend_API.c
+++ b/Zend/zend_API.c
@@ -262,7 +262,6 @@ ZEND_API ZEND_COLD void ZEND_FASTCALL zend_wrong_parameter_error(zpp_error error
ZEND_ASSERT(EG(exception) && "Should have produced an error already");
break;
case ZPP_ERROR_OK:
- case ZPP_ERROR_WRONG_COUNT:
ZEND_UNREACHABLE();
}
}
diff --git a/Zend/zend_API.h b/Zend/zend_API.h
index e83aec34ef0e..a3e4e1690d6c 100644
--- a/Zend/zend_API.h
+++ b/Zend/zend_API.h
@@ -1599,7 +1599,6 @@ C23_ENUM(zpp_error, uint8_t) {
ZPP_ERROR_WRONG_CLASS_OR_LONG,
ZPP_ERROR_WRONG_CLASS_OR_LONG_OR_NULL,
ZPP_ERROR_WRONG_ARG,
- ZPP_ERROR_WRONG_COUNT,
ZPP_ERROR_UNEXPECTED_EXTRA_NAMED,
ZPP_ERROR_WRONG_CALLBACK_OR_NULL,
};