`DiagnosticsFormatter` crashes when source code contains an emoji
Matejkob opened this issue · 1 comments
Matejkob commented
Description
DiagnosticsFormatter
crashes with a Fatal error: Range requires lowerBound <= upperBound
message when the source code contains an emoji.
Steps to Reproduce
Run:
swift run swift-parser-cli print-diags -s 'func o() {
_ = {
0
/x}}1️⃣} /
2
}
}'
This version:
swift run swift-parser-cli print-diags -s 'func o() {
_ = {
0
/x}}$} /
2
}
}'
works.
Tested on main
.
ahoppen commented
Tracked in Apple’s issue tracker as rdar://123409748