Closed
Description
This is a tracking issue for const char conversions. List of functions belonging to !#[feature(const_char_from_u32_unchecked)]
:
impl char {
pub const unsafe fn from_u32_unchecked(i: u32) -> char;
}
// Available through core::char and std::char
mod char {
pub const unsafe fn from_u32_unchecked(i: u32) -> char;
}
List of functions belonging to stable #![feature(const_char_convert)]
:
impl char {
pub const fn from_u32(self, i: u32) -> Option<char>;
pub const fn from_digit(self, num: u32, radix: u32) -> Option<char>;
pub const fn to_digit(self, radix: u32) -> Option<u32>;
}
// Available through core::char and std::char
mod char {
pub const fn from_u32(i: u32) -> Option<char>;
pub const fn from_digit(num: u32, radix: u32) -> Option<char>;
}
Steps:
- Introduced by Make char conversion functions unstably const #89258
- Partially stabilized by Stabilize const char convert #102470 ,
const_char_from_u32_unchecked
is still unstable. Stabilization is probably blocked by const panicing.Edit: const panic is stable now!Stabilization is blocked by Option::unwrap const stability, which is blocked by Tracking issue for#![feature(const_precise_live_drops)]
#73255.- Stabilize const unchecked conversion from u32 to char #126958