diff options
| author | U.Nakamura <usa@ruby-lang.org> | 2023-06-26 20:07:43 +0900 |
|---|---|---|
| committer | U.Nakamura <usa@ruby-lang.org> | 2023-06-26 20:07:43 +0900 |
| commit | 0275614ba213dfb6f05743a16f65623bc3b6e274 (patch) | |
| tree | 4b5c4f9a4d4ddf870949cd930f78348a0a7b02e5 /test/ruby | |
| parent | 504f37af3d36c438a1b7604b10b12f56dfb66d8e (diff) | |
merge revision(s) 2c8f287: [Backport #19532]
Fix handling of 6-byte codepoints in left_adjust_char_head in CESU-8
encoding
---
enc/cesu_8.c | 23 +++++++++++++++++++----
test/ruby/enc/test_cesu8.rb | 4 ++++
2 files changed, 23 insertions(+), 4 deletions(-)
Diffstat (limited to 'test/ruby')
| -rw-r--r-- | test/ruby/enc/test_cesu8.rb | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/test/ruby/enc/test_cesu8.rb b/test/ruby/enc/test_cesu8.rb index d9debe76cd..68a08389ea 100644 --- a/test/ruby/enc/test_cesu8.rb +++ b/test/ruby/enc/test_cesu8.rb @@ -106,4 +106,8 @@ EOT assert_equal chr, ord.chr("cesu-8") end end + + def test_cesu8_left_adjust_char_head + assert_equal("", "\u{10000}".encode("cesu-8").chop) + end end |
