File tree Expand file tree Collapse file tree 2 files changed +5
-6
lines changed Expand file tree Collapse file tree 2 files changed +5
-6
lines changed Original file line number Diff line number Diff line change @@ -314,8 +314,7 @@ fn obtain_lint_annotations(file: &str) -> (Vec<DMLStyleError>,
314314 last_line = row;
315315 if let Some ( capture) = LINT_ANNOTATION . captures ( line) {
316316 let has_pre = capture. get ( 1 )
317- . map_or ( false ,
318- |m|!m. is_empty ( ) &&
317+ . is_some_and ( |m|!m. is_empty ( ) &&
319318 JUST_WHITESPACE . captures ( m. as_str ( ) ) . is_none ( ) ) ;
320319 let op_capture = capture. get ( 2 ) . unwrap ( ) ;
321320 let operation = match op_capture. as_str ( ) {
@@ -421,7 +420,7 @@ fn remove_disabled_lints(errors: &mut Vec<DMLStyleError>,
421420 !annotations. whole_file . contains (
422421 & LintAnnotation :: Allow ( error. rule_type ) ) &&
423422 !annotations. line_specific . get ( & error. error . range . row_start . 0 )
424- . map_or ( false , |annots|annots. contains (
423+ . is_some_and ( |annots|annots. contains (
425424 & LintAnnotation :: Allow ( error. rule_type ) ) )
426425 }
427426 ) ;
Original file line number Diff line number Diff line change @@ -794,11 +794,11 @@ impl IndentContinuationLineArgs {
794794 DMLObjectContent :: Typedef ( _) => {
795795 let mut tokens = node. tokens ( ) ;
796796 Self :: filter_out_last_semi_ranges ( & mut tokens) ;
797- return Some ( IndentContinuationLineArgs {
797+ Some ( IndentContinuationLineArgs {
798798 token_list : IndentParenExprArgs :: filter_out_parenthesized_tokens ( tokens) ,
799799 expected_depth : depth,
800800 } ) } ,
801- _ => return None ,
801+ _ => None ,
802802 }
803803 }
804804}
@@ -817,7 +817,7 @@ impl IndentContinuationLineRule {
817817 }
818818 }
819819
820- pub fn check < ' a > ( & self , acc : & mut Vec < DMLStyleError > ,
820+ pub fn check ( & self , acc : & mut Vec < DMLStyleError > ,
821821 args : Option < IndentContinuationLineArgs > ) {
822822 if !self . enabled { return ; }
823823 let Some ( args) = args else { return ; } ;
You can’t perform that action at this time.
0 commit comments