@@ -364,7 +364,7 @@ impl LiteralDigitGrouping {
364364 if_chain ! {
365365 if let Some ( src) = snippet_opt( cx, lit. span) ;
366366 if let Some ( firstch) = src. chars( ) . next( ) ;
367- if char :: to_digit ( firstch, 10 ) . is_some ( ) ;
367+ if char :: is_digit ( firstch, 10 ) ;
368368 then {
369369 let digit_info = DigitInfo :: new( & src, false ) ;
370370 let _ = Self :: do_lint( digit_info. digits, digit_info. suffix, in_macro) . map_err( |warning_type| {
@@ -378,7 +378,7 @@ impl LiteralDigitGrouping {
378378 if_chain ! {
379379 if let Some ( src) = snippet_opt( cx, lit. span) ;
380380 if let Some ( firstch) = src. chars( ) . next( ) ;
381- if char :: to_digit ( firstch, 10 ) . is_some ( ) ;
381+ if char :: is_digit ( firstch, 10 ) ;
382382 then {
383383 let digit_info = DigitInfo :: new( & src, true ) ;
384384 // Separate digits into integral and fractional parts.
@@ -512,7 +512,7 @@ impl DecimalLiteralRepresentation {
512512 if let LitKind :: Int ( val, _) = lit. kind;
513513 if let Some ( src) = snippet_opt( cx, lit. span) ;
514514 if let Some ( firstch) = src. chars( ) . next( ) ;
515- if char :: to_digit ( firstch, 10 ) . is_some ( ) ;
515+ if char :: is_digit ( firstch, 10 ) ;
516516 let digit_info = DigitInfo :: new( & src, false ) ;
517517 if digit_info. radix == Radix :: Decimal ;
518518 if val >= u128 :: from( self . threshold) ;
0 commit comments