1--TEST-- 2Bug #68447: grapheme_extract take an extra trailing character 3--SKIPIF-- 4<?php if( !extension_loaded( 'intl' ) ) print 'skip'; ?> 5--FILE-- 6<?php 7$katsushikaku = "葛飾区"; 8echo grapheme_extract($katsushikaku, 1) . "\n"; 9 10$haiyore = "這いよれ"; 11echo grapheme_extract($haiyore, 1, GRAPHEME_EXTR_COUNT) . "\n"; 12echo grapheme_extract($haiyore, 2, GRAPHEME_EXTR_COUNT) . "\n"; 13echo grapheme_extract($haiyore, 6, GRAPHEME_EXTR_MAXBYTES) . "\n"; 14echo grapheme_extract($haiyore, 9, GRAPHEME_EXTR_MAXBYTES) . "\n"; 15echo grapheme_extract($haiyore, 12, GRAPHEME_EXTR_MAXBYTES) . "\n"; 16echo grapheme_extract($haiyore, 1, GRAPHEME_EXTR_MAXCHARS) . "\n"; 17echo grapheme_extract($haiyore, 2, GRAPHEME_EXTR_MAXCHARS) . "\n"; 18echo grapheme_extract($haiyore, 3, GRAPHEME_EXTR_MAXCHARS) . "\n"; 19--EXPECT-- 20葛 21這 22這い 23 24這 25這い 26 27這 28這い 29