1--TEST--
2IntlCodepointBreakIterator's part iterator
3--SKIPIF--
4<?php
5if (!extension_loaded('intl'))
6    die('skip intl extension not enabled');
7--FILE--
8<?php
9ini_set("intl.error_level", E_WARNING);
10ini_set("intl.default_locale", "pt_PT");
11
12$text = 'ตัวอย่างข้อความ';
13
14$it = IntlBreakIterator::createCodePointInstance()->getPartsIterator();
15$it->getBreakIterator()->setText($text);
16
17foreach ($it as $k => $v) {
18    echo "$k. $v (" . sprintf("U+%04X", $it->getBreakIterator()->getLastCodePoint()) .
19        ") at {$it->getBreakIterator()->current()}\r\n";
20}
21
22?>
23--EXPECT--
240. ต (U+0E15) at 3
251. ั (U+0E31) at 6
262. ว (U+0E27) at 9
273. อ (U+0E2D) at 12
284. ย (U+0E22) at 15
295. ่ (U+0E48) at 18
306. า (U+0E32) at 21
317. ง (U+0E07) at 24
328. ข (U+0E02) at 27
339. ้ (U+0E49) at 30
3410. อ (U+0E2D) at 33
3511. ค (U+0E04) at 36
3612. ว (U+0E27) at 39
3713. า (U+0E32) at 42
3814. ม (U+0E21) at 45
39