Download src/php/php-src/Zend/tests/anon/013.phpt from meddyrat/dis-bench: direct link, hf CLI and curl.
- Browser
- Download file 242 Bytes
-
https://huggingface.co/datasets/meddyrat/dis-bench/resolve/main/src/php/php-src/Zend/tests/anon/013.phpt
- Command line
-
hf download hf://datasets/meddyrat/dis-bench/src/php/php-src/Zend/tests/anon/013.phpt
-
curl -L -o 013.phpt https://huggingface.co/datasets/meddyrat/dis-bench/resolve/main/src/php/php-src/Zend/tests/anon/013.phpt
242 Bytes
| --TEST-- | |
| closure binding to anonymous class | |
| --FILE-- | |
| $class = new class {}; | |
| $foo = function() { | |
| return $this; | |
| }; | |
| $closure = Closure::bind($foo, $class, $class); | |
| var_dump($closure()); | |
| --EXPECT-- | |
| object(class@anonymous)#1 (0) { | |
| } | |