File tree Expand file tree Collapse file tree 2 files changed +2
-6
lines changed Expand file tree Collapse file tree 2 files changed +2
-6
lines changed Original file line number Diff line number Diff line change @@ -104,11 +104,7 @@ fn swap_with_default<T: Default>(value: &mut T) -> T {
104
104
105
105
fn maybe_numeric_string < S : Into < AwkString > > ( str : S ) -> AwkString {
106
106
let mut str = str. into ( ) ;
107
- let numeric_string = is_valid_number (
108
- str. as_str ( )
109
- . trim ( )
110
- . trim_start_matches ( |c| c == '+' || c == '-' ) ,
111
- ) ;
107
+ let numeric_string = is_valid_number ( str. as_str ( ) . trim ( ) . trim_start_matches ( [ '+' , '-' ] ) ) ;
112
108
str. is_numeric = numeric_string;
113
109
str
114
110
}
Original file line number Diff line number Diff line change @@ -65,7 +65,7 @@ fn parse_output_format<'a>(
65
65
posix_fields : & ' a HashMap < & ' a str , & ' a str > ,
66
66
) -> Vec < & ' a str > {
67
67
format
68
- . split ( |c| c == ' ' || c == ',' )
68
+ . split ( [ ' ' , ',' ] )
69
69
. map ( |s| {
70
70
let field = s. split ( '=' ) . next ( ) . unwrap_or ( "" ) . trim ( ) ;
71
71
if posix_fields. contains_key ( field) {
You can’t perform that action at this time.
0 commit comments