-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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
RFC: Support char::encode_utf8
in const scenarios.
#3696
Conversation
…ionale and alternatives.
Changes this small don't require an RFC. |
Oh, alright then. I'll just submit the implementation directly. Should I just close this PR now? |
libs-api needs to discuss all library-related API changes. A PR to rust-lang/rust with a libs-api reviewer is fine for anything relatively trivial (like this, adding It looks like you already put a PR up at rust-lang/rust#130511, so this can be closed. Thanks for putting in the effort! |
… r=dtolnay Support `char::encode_utf8` in const scenarios. This PR implements [`rust-lang/rfcs#3696`](rust-lang/rfcs#3696). This assumes [`const_slice_from_raw_parts_mut`](rust-lang#67456).
…=dtolnay Support `char::encode_utf8` in const scenarios. This PR implements [`rust-lang/rfcs#3696`](rust-lang/rfcs#3696). This assumes [`const_slice_from_raw_parts_mut`](rust-lang#67456).
Support `char::encode_utf8` in const scenarios. This PR implements [`rust-lang/rfcs#3696`](rust-lang/rfcs#3696). This assumes [`const_slice_from_raw_parts_mut`](rust-lang/rust#67456).
The
encode_utf8
method inchar
should be marked const to support compile-time conversions.Rendered