We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents a9ee1d0 + 66209cd commit f14637bCopy full SHA for f14637b
library/core/src/char/methods.rs
@@ -320,8 +320,9 @@ impl char {
320
/// '1'.is_digit(37);
321
/// ```
322
#[stable(feature = "rust1", since = "1.0.0")]
323
+ #[rustc_const_unstable(feature = "const_char_is_digit", issue = "132241")]
324
#[inline]
- pub fn is_digit(self, radix: u32) -> bool {
325
+ pub const fn is_digit(self, radix: u32) -> bool {
326
self.to_digit(radix).is_some()
327
}
328
0 commit comments