diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/rust/src/main.rs | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/src/rust/src/main.rs b/src/rust/src/main.rs index 083a99f..7d4463c 100644 --- a/src/rust/src/main.rs +++ b/src/rust/src/main.rs @@ -165,13 +165,13 @@ fn main() { // Fill in common print data let data = CommonPrintData { - length: length, + length, alpha: &alpha, alnum: &alnum, - printbool: printbool, - printlen: printlen, - col_width: col_width, - col_num: col_num, + printbool, + printlen, + col_width, + col_num, }; // @@ -181,7 +181,7 @@ fn main() { // Normal passwords print_columns("Normal passwords", number, &normal, &data); - println!(""); + println!(); // Special passwords print_columns( @@ -203,7 +203,7 @@ fn main() { let words = reader.lines().map(|l| l.unwrap()).collect(); // Print - println!(""); + println!(); println!("Passphrases:"); for _ in 0..number / 2 { @@ -215,7 +215,7 @@ fn main() { // // Print passwords in neat columns // -fn print_columns(title: &str, num: u8, chars: &Vec<char>, data: &CommonPrintData) { +fn print_columns(title: &str, num: u8, chars: &[char], data: &CommonPrintData) { let mut strings: Vec<String> = Vec::new(); for _ in 0..num { strings.push(randstring(data.length, chars, data.alpha, data.alnum)); |