[php-src] PR #20795: Add tests for strlen() with invalid argument types
| From: | distvan | Date: | Sun, 28 Dec 2025 17:22:43 +0000 |
| Subject: | [php-src] PR #20795: Add tests for strlen() with invalid argument types | ||
| Groups: | php.git-pulls | ||
| Request: | Send a blank email to git-pulls+get-34403@lists.php.net to get a copy of this message | ||
Pull Request: https://github.com/php/php-src/pull/20795
Author: distvan
This PR adds missing Zend tests for strlen() when called with invalid
argument types that are rejected by the engine before the function
implementation is reached.
Covered cases:
- resource argument
- object without __toString()
- enum case (PHP 8.1+)
All tests assert the user-visible error message and are placed under
Zend/tests/, consistent with existing strlen invalid-type coverage
(e.g. strlen_deprecation_to_exception.phpt).