Download src/php/php-src/ext/iconv/tests/bug74230.phpt from meddyrat/dis-bench: direct link, hf CLI and curl.
- Browser
- Download file 397 Bytes
-
https://huggingface.co/datasets/meddyrat/dis-bench/resolve/main/src/php/php-src/ext/iconv/tests/bug74230.phpt
- Command line
-
hf download hf://datasets/meddyrat/dis-bench/src/php/php-src/ext/iconv/tests/bug74230.phpt
-
curl -L -o bug74230.phpt https://huggingface.co/datasets/meddyrat/dis-bench/resolve/main/src/php/php-src/ext/iconv/tests/bug74230.phpt
397 Bytes
| --TEST-- | |
| Bug #74230 iconv fails to fail on surrogates | |
| --EXTENSIONS-- | |
| iconv | |
| --FILE-- | |
| $high = "\xED\xa1\x92"; // codepoint D852 | |
| $low = "\xED\xBD\xA2"; // codepoint DF62 | |
| $pair = $high.$low; | |
| var_dump( | |
| @\iconv('UTF-8', 'UTF-8', $high) === false, | |
| @\iconv('UTF-8', 'UTF-8', $low) === false, | |
| @\iconv('UTF-8', 'UTF-8', $pair) === false | |
| ); | |
| --EXPECT-- | |
| bool(true) | |
| bool(true) | |
| bool(true) | |