Skip to content

Wrong uppercase for ß #79660

Closed
Closed
@vbrandl

Description

@vbrandl

I tried this code:

println!("{}", 'ß'.to_uppercase());

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 think to_uppercase should return the actual uppercase letter instead of SS.

Meta

rustc --version --verbose:

rustc 1.48.0 (7eac88abb 2020-11-16)
binary: rustc
commit-hash: 7eac88abb2e57e752f3302f02be5f3ce3d7adfb4
commit-date: 2020-11-16
host: x86_64-unknown-linux-gnu
release: 1.48.0
LLVM version: 11.0

rustc +nightly --version --verbose:

rustc 1.50.0-nightly (1c389ffef 2020-11-24)
binary: rustc
commit-hash: 1c389ffeff814726dec325f0f2b0c99107df2673
commit-date: 2020-11-24
host: x86_64-unknown-linux-gnu
release: 1.50.0-nightly

Metadata

Metadata

Assignees

No one assigned

    Labels

    A-UnicodeArea: UnicodeC-bugCategory: This is a bug.T-libs-apiRelevant to the library API team, which will review and decide on the PR/issue.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions