[php-src] PR #14442: refactor: use ZEND_PARSE_PARAMETERS_NONE in spl_iterators.c
| From: | morrisonlevi | Date: | Sun, 02 Jun 2024 17:43:58 +0000 |
| Subject: | [php-src] PR #14442: refactor: use ZEND_PARSE_PARAMETERS_NONE in spl_iterators.c | ||
| Groups: | php.git-pulls | ||
| Request: | Send a blank email to git-pulls+get-26496@lists.php.net to get a copy of this message | ||
Pull Request: https://github.com/php/php-src/pull/14442
Author: morrisonlevi
Prefer:
```c
ZEND_PARSE_PARAMETERS_NONE();
```
Over:
```c
if (zend_parse_parameters_none() == FAILURE) {
RETURN_THROWS();
}
```
It's shorter, more modern, and they do the same thing. Technically, ZEND_PARSE_PARAMETERS_NONE
doesn't check that there's an exception, but it generates one, so it's still
cohesive.