xref: /PHP-8.3/ext/pcre/tests/bug42737.phpt (revision 66a24c86)
1--TEST--
2Bug #42737 (preg_split('//u') triggers a E_NOTICE with newlines)
3--FILE--
4<?php
5
6$string = chr(13).chr(10);
7
8$array = preg_split('//u', $string, - 1, PREG_SPLIT_NO_EMPTY);
9
10var_dump(array_map('ord', $array));
11
12?>
13--EXPECT--
14array(2) {
15  [0]=>
16  int(13)
17  [1]=>
18  int(10)
19}
20