Download src/php/php-src/Zend/tests/closures/bug69802_2.phpt from meddyrat/dis-bench: direct link, hf CLI and curl.
- Browser
- Download file 476 Bytes
-
https://huggingface.co/datasets/meddyrat/dis-bench/resolve/main/src/php/php-src/Zend/tests/closures/bug69802_2.phpt
- Command line
-
hf download hf://datasets/meddyrat/dis-bench/src/php/php-src/Zend/tests/closures/bug69802_2.phpt
-
curl -L -o bug69802_2.phpt https://huggingface.co/datasets/meddyrat/dis-bench/resolve/main/src/php/php-src/Zend/tests/closures/bug69802_2.phpt
476 Bytes
| --TEST-- | |
| Bug #69802 (Reflection on Closure::__invoke borks type hint class name) | |
| --FILE-- | |
| $f = (new ReflectionFunction('iterator_to_array'))->getClosure(); | |
| $r = new ReflectionMethod($f, '__invoke'); | |
| var_dump($r->getParameters()[0]->getClass()); | |
| --EXPECTF-- | |
| Deprecated: Method ReflectionParameter::getClass() is deprecated since 8.0, use ReflectionParameter::getType() instead in %s on line %d | |
| object(ReflectionClass)#4 (1) { | |
| ["name"]=> | |
| string(11) "Traversable" | |
| } | |