mirror of
https://github.com/uutils/coreutils
synced 2024-11-16 09:48:03 +00:00
fix clippy warnings
This commit is contained in:
parent
be8650278b
commit
1b824f4914
3 changed files with 3 additions and 3 deletions
|
@ -113,7 +113,7 @@ pub fn parse_num(src: &str) -> Result<(usize, bool), ParseSizeError> {
|
|||
return Err(ParseSizeError::ParseFailure(src.to_string()));
|
||||
}
|
||||
|
||||
parse_size(&size_string).map(|n| (n, all_but_last))
|
||||
parse_size(size_string).map(|n| (n, all_but_last))
|
||||
}
|
||||
|
||||
#[cfg(test)]
|
||||
|
|
|
@ -278,7 +278,7 @@ struct ByteSplitter {
|
|||
impl ByteSplitter {
|
||||
fn new(settings: &Settings) -> ByteSplitter {
|
||||
let size_string = &settings.strategy_param;
|
||||
let size_num = match parse_size(&size_string) {
|
||||
let size_num = match parse_size(size_string) {
|
||||
Ok(n) => n,
|
||||
Err(e) => crash!(1, "invalid number of bytes: {}", e.to_string()),
|
||||
};
|
||||
|
|
|
@ -419,5 +419,5 @@ fn parse_num(src: &str) -> Result<(usize, bool), ParseSizeError> {
|
|||
return Err(ParseSizeError::ParseFailure(src.to_string()));
|
||||
}
|
||||
|
||||
parse_size(&size_string).map(|n| (n, starting_with))
|
||||
parse_size(size_string).map(|n| (n, starting_with))
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue