pub const fn digit_to_char_const(digit: u32, radix: u32) -> u8
Convert a digit to a character with a radix known at compile time.
This optimizes for cases where radix is <= 10, and uses a decent, match-based fallback algorithm.