Skip to content

Make char::is_private_use and char::is_assigned unstably public#157946

Open
Jules-Bertholet wants to merge 2 commits into
rust-lang:mainfrom
Jules-Bertholet:char-unassigned-private-use
Open

Make char::is_private_use and char::is_assigned unstably public#157946
Jules-Bertholet wants to merge 2 commits into
rust-lang:mainfrom
Jules-Bertholet:char-unassigned-private-use

Conversation

@Jules-Bertholet

@Jules-Bertholet Jules-Bertholet commented Jun 15, 2026

Copy link
Copy Markdown
Contributor

See also #157944, #154849. These functions are used in the implementation of char::escape_debug(), and there's no reason to force crates to duplicate data tables that std has to ship anyway. is_assigned is especially useful because crates relying on the stability guarantees of the other Unicode methods in char may wish to reject unassigned characters where those guarantees do not hold.

I'll add a tracking issue if this is approved.

The is_assigned vs is_unassigned bikeshed probably needs libs-API review before merging?

@rustbot label A-Unicode T-libs-api

r? @Mark-Simulacrum

@rustbot rustbot added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-libs Relevant to the library team, which will review and decide on the PR/issue. A-Unicode Area: Unicode T-libs-api Relevant to the library API team, which will review and decide on the PR/issue. labels Jun 15, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

A-Unicode Area: Unicode S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-libs Relevant to the library team, which will review and decide on the PR/issue. T-libs-api Relevant to the library API team, which will review and decide on the PR/issue.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants