Bug 23474 – Grapheme should end after carriage return if not followed by line feed.
Status
RESOLVED
Resolution
FIXED
Severity
normal
Priority
P3
Component
phobos
Product
D
Version
D2
Platform
All
OS
All
Creation time
2022-11-10T14:38:13Z
Last change time
2023-01-20T08:35:49Z
Keywords
pull
Assigned to
No Owner
Creator
Ate Eskola
Comments
Comment #0 by Ajieskola — 2022-11-10T14:38:13Z
The only time a grapheme can continue after carriage return is when it's followed by a line feed character. Otherwise it must break, even if followed by an extending character: https://www.unicode.org/reports/tr29/tr29-41.html#GB4.
Thus
---
byGrapheme("\r\u0308").walkLength.writeln;
---
...should print 2, but it currently prints 1.
Comment #1 by dlang-bot — 2022-12-31T16:13:23Z
@dukc created dlang/phobos pull request #8657 "Fixed many issues in grapheme walker" fixing this issue:
- Fix issue 23474 - Fixed many issues in grapheme walker
https://github.com/dlang/phobos/pull/8657
Comment #2 by dlang-bot — 2023-01-12T23:09:18Z
@rikkimax created dlang/phobos pull request #8665 "[DO NOT MERGE] Grapheme emoji support in std.uni" fixing this issue:
- Fix issue 23474 - Fixed many issues in grapheme walker
https://github.com/dlang/phobos/pull/8665
Comment #3 by dlang-bot — 2023-01-20T08:35:49Z
dlang/phobos pull request #8657 "Fixed many issues in grapheme walker" was merged into master:
- b334d4ddb2181744e9104249d826b5263762c4b2 by Ate Eskola:
Fix issue 23474 - Fixed many issues in grapheme walker
https://github.com/dlang/phobos/pull/8657