mirror of
https://github.com/rust-lang/rust.git
synced 2026-05-21 17:52:12 +03:00
c1ccdb7d0c
Support `char::encode_utf16` in const scenarios. Relevant tracking issue: #130660 The method `char::encode_utf16` should be marked "const" to allow compile-time conversions. This PR additionally rewrites the `encode_utf16_raw` function for better readability whilst also reducing the amount of unsafe code. try-job: x86_64-msvc