Download src/php/php-src/Zend/tests/foreach/bug39036.phpt from meddyrat/dis-bench: direct link, hf CLI and curl.
- Browser
- Download file 284 Bytes
-
https://huggingface.co/datasets/meddyrat/dis-bench/resolve/main/src/php/php-src/Zend/tests/foreach/bug39036.phpt
- Command line
-
hf download hf://datasets/meddyrat/dis-bench/src/php/php-src/Zend/tests/foreach/bug39036.phpt
-
curl -L -o bug39036.phpt https://huggingface.co/datasets/meddyrat/dis-bench/resolve/main/src/php/php-src/Zend/tests/foreach/bug39036.phpt
284 Bytes
| --TEST-- | |
| Bug #39036 (Unsetting key of foreach() yields segmentation fault) | |
| --FILE-- | |
| $key = 'asdf'; | |
| foreach (get_defined_vars() as $key => $value) { | |
| unset($$key); | |
| } | |
| var_dump($key); | |
| echo "Done\n"; | |
| --EXPECTF-- | |
| Warning: Undefined variable $key in %s on line %d | |
| NULL | |
| Done | |