From 68fc37a646190eca80b2fa9629c62b98a2093fc5 Mon Sep 17 00:00:00 2001 From: Jens Getreu Date: Wed, 6 Nov 2019 17:12:40 +0100 Subject: [PATCH] Rust format --- src/codec/ascii.rs | 1 - src/mission.rs | 12 +++--------- src/scanner.rs | 4 ++-- 3 files changed, 5 insertions(+), 12 deletions(-) diff --git a/src/codec/ascii.rs b/src/codec/ascii.rs index 5b2c5c1..cf1d292 100644 --- a/src/codec/ascii.rs +++ b/src/codec/ascii.rs @@ -156,5 +156,4 @@ mod tests { assert_eq!(offset, 3); assert_eq!(err.unwrap().upto, 4); } - } diff --git a/src/mission.rs b/src/mission.rs index c0ecdc8..f7350e6 100644 --- a/src/mission.rs +++ b/src/mission.rs @@ -204,11 +204,7 @@ pub struct Missions { impl Missions { /// Constructor. We assume that at least one encoding exist. - pub fn new( - encodings: &[String], - control_chars: &ControlChars, - flag_bytes: Option, - ) -> Self { + pub fn new(encodings: &[String], control_chars: &ControlChars, flag_bytes: Option) -> Self { let mut v = Vec::new(); let control_char_filtering = match *control_chars { @@ -302,9 +298,7 @@ impl Missions { { eprintln!( "Warning: range in `{}` extended to range `U+{:x}..U+{:x}`.", - enc_opt, - u_lower_ext, - u_upper_ext + enc_opt, u_lower_ext, u_upper_ext ); } @@ -366,7 +360,7 @@ mod tests { #[test] fn test_enc_opt_parser() { // The following work-around will become obsolete with the upcoming - // [Make `ParseIntError` and `IntErrorKind` fully public · + // [Make `ParseIntError` and `IntErrorKind` fully public · // Pull Request #55705](https://github.com/rust-lang/rust/pull/55705/files) // let pie = ParseIntError {kind: std::num::InvalidDigit} //is private let pie_invalid_digit = CliError::Format(u32::from_str("x").unwrap_err()); diff --git a/src/scanner.rs b/src/scanner.rs index 0c72f58..4a3c6a8 100644 --- a/src/scanner.rs +++ b/src/scanner.rs @@ -1102,7 +1102,7 @@ mod tests { /* println!("Scan of random Bytes:{:?} {:?} {:?} {:?}", res0.v, res1.v, res2.v, res3.v); - */ } + */ + } } - }