Download src/php/php-src/Zend/tests/closures/closure_022.phpt from meddyrat/dis-bench: direct link, hf CLI and curl.
- Browser
- Download file 268 Bytes
-
https://huggingface.co/datasets/meddyrat/dis-bench/resolve/main/src/php/php-src/Zend/tests/closures/closure_022.phpt
- Command line
-
hf download hf://datasets/meddyrat/dis-bench/src/php/php-src/Zend/tests/closures/closure_022.phpt
-
curl -L -o closure_022.phpt https://huggingface.co/datasets/meddyrat/dis-bench/resolve/main/src/php/php-src/Zend/tests/closures/closure_022.phpt
268 Bytes
| --TEST-- | |
| Closure 022: Closure properties | |
| --FILE-- | |
| $a = 0; | |
| $foo = function() use ($a) { | |
| }; | |
| $foo->a = 1; | |
| --EXPECTF-- | |
| Fatal error: Uncaught Error: Cannot create dynamic property Closure::$a in %s:%d | |
| Stack trace: | |
| #0 {main} | |
| thrown in %sclosure_022.php on line 5 | |