File tree 1 file changed +3
-0
lines changed
src/tools/rust-analyzer/crates/hir-ty/src/diagnostics/match_check
1 file changed +3
-0
lines changed Original file line number Diff line number Diff line change @@ -348,6 +348,7 @@ impl Constructor {
348
348
349
349
fn as_slice ( & self ) -> Option < Slice > {
350
350
match self {
351
+ #[ allow( unreachable_code) ]
351
352
Slice ( slice) => Some ( * slice) ,
352
353
_ => None ,
353
354
}
@@ -470,6 +471,7 @@ impl Constructor {
470
471
( IntRange ( self_range) , IntRange ( other_range) ) => self_range. is_covered_by ( other_range) ,
471
472
( FloatRange ( void) , FloatRange ( ..) ) => match * void { } ,
472
473
( Str ( void) , Str ( ..) ) => match * void { } ,
474
+ #[ allow( unreachable_code) ]
473
475
( Slice ( self_slice) , Slice ( other_slice) ) => self_slice. is_covered_by ( * other_slice) ,
474
476
475
477
// We are trying to inspect an opaque constant. Thus we skip the row.
@@ -502,6 +504,7 @@ impl Constructor {
502
504
. iter ( )
503
505
. filter_map ( |c| c. as_int_range ( ) )
504
506
. any ( |other| range. is_covered_by ( other) ) ,
507
+ #[ allow( unreachable_code) ]
505
508
Slice ( slice) => used_ctors
506
509
. iter ( )
507
510
. filter_map ( |c| c. as_slice ( ) )
You can’t perform that action at this time.
0 commit comments