-
Notifications
You must be signed in to change notification settings - Fork 13.3k
Wrong uppercase for ß
#79660
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
(quickly scraped from https://en.wikipedia.org/wiki/%C3%9F#Capital_form) I have never seen |
While both are valid and the former one is used more often (actually I've never seen a capital |
Rust follows case mapping rules specified by Unicode, which specs that ß must map to SS under default SpecialCasing rules. |
This has been the case since #26039 |
So, given this -- is there even a bug here? One might consider this a Unicode bug, but even that is not clear, and Rust seems to be working as intended by matching what Unicode specifies. |
Unicode doesn't consider it a bug - https://www.unicode.org/faq/casemap_charprop.html#11 |
All right, closing as "not a bug" then. Thanks all! |
I tried this code:
I expected to see this happen:
I expected this to print
ẞ
(see Capitalẞ
).Instead, this happened:
The code printed
SS
which is often use to representß
in uppercase.Since there is a dedicated character for the capital
ẞ
(which looks really similar to the lowercaseß
in this font), I thinkto_uppercase
should return the actual uppercase letter instead ofSS
.Meta
rustc --version --verbose
:rustc +nightly --version --verbose
:The text was updated successfully, but these errors were encountered: