Re: iterator_count signature for iterables
| From: | Tim Düsterhus | Date: | Tue, 26 Nov 2024 11:07:43 +0000 |
| Subject: | Re: iterator_count signature for iterables | ||
| References: | 1 2 3 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-126055@lists.php.net to get a copy of this message | ||
Hi
Am 2024-11-26 12:00, schrieb Marco Pivetta:
IsSince PHP 8.2Traversable|arrayan alias ofiterable? Is it **always** like that?
iterable is internally transformed into Traversable|array on the engine level: https://github.com/php/php-src/pull/7309. iterable no longer exists as a type since then. But even before that it was *semantically* identical, but technically it was a distinct type.
Best regards
Tim Düsterhus