[INFO] cloning repository https://github.com/bantic/cryptopals [INFO] running `Command { std: "git" "-c" "credential.helper=" "-c" "credential.helper=/workspace/cargo-home/bin/git-credential-null" "clone" "--bare" "https://github.com/bantic/cryptopals" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Fbantic%2Fcryptopals", kill_on_drop: false }` [INFO] [stderr] Cloning into bare repository '/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Fbantic%2Fcryptopals'... [INFO] running `Command { std: "git" "rev-parse" "HEAD", kill_on_drop: false }` [INFO] [stdout] f0958d66e32c4ca18ace0e3c208066514b769e6c [INFO] testing bantic/cryptopals against beta-2022-04-10 for beta-1.61-1 [INFO] running `Command { std: "git" "clone" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Fbantic%2Fcryptopals" "/workspace/builds/worker-27/source", kill_on_drop: false }` [INFO] [stderr] Cloning into '/workspace/builds/worker-27/source'... [INFO] [stderr] done. [INFO] validating manifest of git repo https://github.com/bantic/cryptopals on toolchain beta-2022-04-10 [INFO] running `Command { std: "/workspace/cargo-home/bin/cargo" "+beta-2022-04-10" "metadata" "--manifest-path" "Cargo.toml" "--no-deps", kill_on_drop: false }` [INFO] started tweaking git repo https://github.com/bantic/cryptopals [INFO] finished tweaking git repo https://github.com/bantic/cryptopals [INFO] tweaked toml for git repo https://github.com/bantic/cryptopals written to /workspace/builds/worker-27/source/Cargo.toml [INFO] crate git repo https://github.com/bantic/cryptopals already has a lockfile, it will not be regenerated [INFO] running `Command { std: "/workspace/cargo-home/bin/cargo" "+beta-2022-04-10" "fetch" "--manifest-path" "Cargo.toml", kill_on_drop: false }` [INFO] [stderr] Blocking waiting for file lock on package cache [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-27/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-27/source:/opt/rustwide/workdir:ro,Z" "-v" "/var/lib/crater-agent-workspace/cargo-home:/opt/rustwide/cargo-home:ro,Z" "-v" "/var/lib/crater-agent-workspace/rustup-home:/opt/rustwide/rustup-home:ro,Z" "-e" "SOURCE_DIR=/opt/rustwide/workdir" "-e" "CARGO_TARGET_DIR=/opt/rustwide/target" "-e" "CARGO_HOME=/opt/rustwide/cargo-home" "-e" "RUSTUP_HOME=/opt/rustwide/rustup-home" "-w" "/opt/rustwide/workdir" "-m" "1610612736" "--user" "0:0" "--network" "none" "ghcr.io/rust-lang/crates-build-env/linux@sha256:b0c94ce3c1162fcb8e57cac5b65ec2f72eabb1eebea4fcc35e269e823f681646" "/opt/rustwide/cargo-home/bin/cargo" "+beta-2022-04-10" "metadata" "--no-deps" "--format-version=1", kill_on_drop: false }` [INFO] [stdout] 3ace56ad9fb49009e98c3e552091a37f149ab1aeda8e04e1831fc3fb072f43b2 [INFO] running `Command { std: "docker" "start" "-a" "3ace56ad9fb49009e98c3e552091a37f149ab1aeda8e04e1831fc3fb072f43b2", kill_on_drop: false }` [INFO] running `Command { std: "docker" "inspect" "3ace56ad9fb49009e98c3e552091a37f149ab1aeda8e04e1831fc3fb072f43b2", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "3ace56ad9fb49009e98c3e552091a37f149ab1aeda8e04e1831fc3fb072f43b2", kill_on_drop: false }` [INFO] [stdout] 3ace56ad9fb49009e98c3e552091a37f149ab1aeda8e04e1831fc3fb072f43b2 [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-27/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-27/source:/opt/rustwide/workdir:ro,Z" "-v" "/var/lib/crater-agent-workspace/cargo-home:/opt/rustwide/cargo-home:ro,Z" "-v" "/var/lib/crater-agent-workspace/rustup-home:/opt/rustwide/rustup-home:ro,Z" "-e" "SOURCE_DIR=/opt/rustwide/workdir" "-e" "CARGO_TARGET_DIR=/opt/rustwide/target" "-e" "CARGO_INCREMENTAL=0" "-e" "RUST_BACKTRACE=full" "-e" "RUSTFLAGS=--cap-lints=warn" "-e" "CARGO_HOME=/opt/rustwide/cargo-home" "-e" "RUSTUP_HOME=/opt/rustwide/rustup-home" "-w" "/opt/rustwide/workdir" "-m" "1610612736" "--user" "0:0" "--network" "none" "ghcr.io/rust-lang/crates-build-env/linux@sha256:b0c94ce3c1162fcb8e57cac5b65ec2f72eabb1eebea4fcc35e269e823f681646" "/opt/rustwide/cargo-home/bin/cargo" "+beta-2022-04-10" "build" "--frozen" "--message-format=json", kill_on_drop: false }` [INFO] [stdout] 3914dd8cb00d610a96da01a245d445cc8869f540f7f350e936bf057a8ed519c1 [INFO] running `Command { std: "docker" "start" "-a" "3914dd8cb00d610a96da01a245d445cc8869f540f7f350e936bf057a8ed519c1", kill_on_drop: false }` [INFO] [stderr] Compiling cryptopals v0.1.0 (/opt/rustwide/workdir) [INFO] [stdout] warning: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/crypto/xor.rs:21:8 [INFO] [stdout] | [INFO] [stdout] 21 | if (score > best_score) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_parens)]` on by default [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 21 - if (score > best_score) { [INFO] [stdout] 21 + if score > best_score { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: cannot borrow `letter_counts` as mutable because it is also borrowed as immutable [INFO] [stdout] --> src/crypto/xor.rs:76:7 [INFO] [stdout] | [INFO] [stdout] 75 | let v = letter_counts.get(&c).unwrap(); [INFO] [stdout] | --------------------- immutable borrow occurs here [INFO] [stdout] 76 | letter_counts.insert(c, v + 1); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^-^^^^^ [INFO] [stdout] | | | [INFO] [stdout] | | immutable borrow later used here [INFO] [stdout] | mutable borrow occurs here [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(mutable_borrow_reservation_conflict)]` on by default [INFO] [stdout] = warning: this borrowing pattern was not meant to be accepted, and may become a hard error in the future [INFO] [stdout] = note: for more information, see issue #59159 [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function is never used: `hex_to_base64` [INFO] [stdout] --> src/crypto/hex_to_base64.rs:4:8 [INFO] [stdout] | [INFO] [stdout] 4 | pub fn hex_to_base64(hex: &str) -> String { [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(dead_code)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function is never used: `pad_bits` [INFO] [stdout] --> src/crypto/hex_to_base64.rs:22:4 [INFO] [stdout] | [INFO] [stdout] 22 | fn pad_bits(bits: Vec) -> Vec { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function is never used: `bits_to_base64` [INFO] [stdout] --> src/crypto/hex_to_base64.rs:31:4 [INFO] [stdout] | [INFO] [stdout] 31 | fn bits_to_base64(bits: Vec) -> char { [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function is never used: `xor` [INFO] [stdout] --> src/crypto/xor.rs:4:8 [INFO] [stdout] | [INFO] [stdout] 4 | pub fn xor(hexed_input: &str, c: char) -> String { [INFO] [stdout] | ^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function is never used: `decode_fixed_xor` [INFO] [stdout] --> src/crypto/xor.rs:14:8 [INFO] [stdout] | [INFO] [stdout] 14 | pub fn decode_fixed_xor(hexed_input: &str) -> String { [INFO] [stdout] | ^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function is never used: `get_char_freq` [INFO] [stdout] --> src/crypto/xor.rs:30:4 [INFO] [stdout] | [INFO] [stdout] 30 | fn get_char_freq(c: char) -> f32 { [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function is never used: `freq_score` [INFO] [stdout] --> src/crypto/xor.rs:62:4 [INFO] [stdout] | [INFO] [stdout] 62 | fn freq_score(str: &str) -> f32 { [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function is never used: `xor_hex` [INFO] [stdout] --> src/crypto/xor_hex.rs:4:8 [INFO] [stdout] | [INFO] [stdout] 4 | pub fn xor_hex(a: &str, b: &str) -> String { [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function is never used: `hex_to_vecu8` [INFO] [stdout] --> src/crypto/mod.rs:9:10 [INFO] [stdout] | [INFO] [stdout] 9 | pub fn hex_to_vecu8(hex: &str) -> Vec { [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function is never used: `hex_to_u8` [INFO] [stdout] --> src/crypto/mod.rs:19:6 [INFO] [stdout] | [INFO] [stdout] 19 | fn hex_to_u8(hex: &str) -> u8 { [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function is never used: `hex_to_decimal` [INFO] [stdout] --> src/crypto/mod.rs:33:10 [INFO] [stdout] | [INFO] [stdout] 33 | pub fn hex_to_decimal(hex: &str) -> i32 { [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function is never used: `decimal_to_bits` [INFO] [stdout] --> src/crypto/mod.rs:37:6 [INFO] [stdout] | [INFO] [stdout] 37 | fn decimal_to_bits(d: i32) -> Vec { [INFO] [stdout] | ^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function is never used: `hex_to_bits` [INFO] [stdout] --> src/crypto/mod.rs:42:10 [INFO] [stdout] | [INFO] [stdout] 42 | pub fn hex_to_bits(hex: &str) -> Vec { [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function is never used: `bits_to_hex` [INFO] [stdout] --> src/crypto/mod.rs:53:10 [INFO] [stdout] | [INFO] [stdout] 53 | pub fn bits_to_hex(bits: Vec) -> String { [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function is never used: `bits_to_decimal` [INFO] [stdout] --> src/crypto/mod.rs:62:10 [INFO] [stdout] | [INFO] [stdout] 62 | pub fn bits_to_decimal(bits: Vec) -> i32 { [INFO] [stdout] | ^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: 17 warnings emitted [INFO] [stdout] [INFO] [stdout] [INFO] [stderr] Finished dev [unoptimized + debuginfo] target(s) in 0.57s [INFO] running `Command { std: "docker" "inspect" "3914dd8cb00d610a96da01a245d445cc8869f540f7f350e936bf057a8ed519c1", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "3914dd8cb00d610a96da01a245d445cc8869f540f7f350e936bf057a8ed519c1", kill_on_drop: false }` [INFO] [stdout] 3914dd8cb00d610a96da01a245d445cc8869f540f7f350e936bf057a8ed519c1 [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-27/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-27/source:/opt/rustwide/workdir:ro,Z" "-v" "/var/lib/crater-agent-workspace/cargo-home:/opt/rustwide/cargo-home:ro,Z" "-v" "/var/lib/crater-agent-workspace/rustup-home:/opt/rustwide/rustup-home:ro,Z" "-e" "SOURCE_DIR=/opt/rustwide/workdir" "-e" "CARGO_TARGET_DIR=/opt/rustwide/target" "-e" "CARGO_INCREMENTAL=0" "-e" "RUST_BACKTRACE=full" "-e" "RUSTFLAGS=--cap-lints=warn" "-e" "CARGO_HOME=/opt/rustwide/cargo-home" "-e" "RUSTUP_HOME=/opt/rustwide/rustup-home" "-w" "/opt/rustwide/workdir" "-m" "1610612736" "--user" "0:0" "--network" "none" "ghcr.io/rust-lang/crates-build-env/linux@sha256:b0c94ce3c1162fcb8e57cac5b65ec2f72eabb1eebea4fcc35e269e823f681646" "/opt/rustwide/cargo-home/bin/cargo" "+beta-2022-04-10" "test" "--frozen" "--no-run" "--message-format=json", kill_on_drop: false }` [INFO] [stdout] 0930eb792720936ba8f3c701983f0238a04908754bd245a428dd8bfee2ad7aef [INFO] running `Command { std: "docker" "start" "-a" "0930eb792720936ba8f3c701983f0238a04908754bd245a428dd8bfee2ad7aef", kill_on_drop: false }` [INFO] [stdout] warning: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/crypto/xor.rs:21:8 [INFO] [stdout] | [INFO] [stdout] 21 | if (score > best_score) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_parens)]` on by default [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 21 - if (score > best_score) { [INFO] [stdout] 21 + if score > best_score { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stderr] Compiling cryptopals v0.1.0 (/opt/rustwide/workdir) [INFO] [stdout] warning: cannot borrow `letter_counts` as mutable because it is also borrowed as immutable [INFO] [stdout] --> src/crypto/xor.rs:76:7 [INFO] [stdout] | [INFO] [stdout] 75 | let v = letter_counts.get(&c).unwrap(); [INFO] [stdout] | --------------------- immutable borrow occurs here [INFO] [stdout] 76 | letter_counts.insert(c, v + 1); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^-^^^^^ [INFO] [stdout] | | | [INFO] [stdout] | | immutable borrow later used here [INFO] [stdout] | mutable borrow occurs here [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(mutable_borrow_reservation_conflict)]` on by default [INFO] [stdout] = warning: this borrowing pattern was not meant to be accepted, and may become a hard error in the future [INFO] [stdout] = note: for more information, see issue #59159 [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function is never used: `hex_to_base64` [INFO] [stdout] --> src/crypto/hex_to_base64.rs:4:8 [INFO] [stdout] | [INFO] [stdout] 4 | pub fn hex_to_base64(hex: &str) -> String { [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(dead_code)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function is never used: `pad_bits` [INFO] [stdout] --> src/crypto/hex_to_base64.rs:22:4 [INFO] [stdout] | [INFO] [stdout] 22 | fn pad_bits(bits: Vec) -> Vec { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function is never used: `bits_to_base64` [INFO] [stdout] --> src/crypto/hex_to_base64.rs:31:4 [INFO] [stdout] | [INFO] [stdout] 31 | fn bits_to_base64(bits: Vec) -> char { [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function is never used: `xor` [INFO] [stdout] --> src/crypto/xor.rs:4:8 [INFO] [stdout] | [INFO] [stdout] 4 | pub fn xor(hexed_input: &str, c: char) -> String { [INFO] [stdout] | ^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function is never used: `decode_fixed_xor` [INFO] [stdout] --> src/crypto/xor.rs:14:8 [INFO] [stdout] | [INFO] [stdout] 14 | pub fn decode_fixed_xor(hexed_input: &str) -> String { [INFO] [stdout] | ^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function is never used: `get_char_freq` [INFO] [stdout] --> src/crypto/xor.rs:30:4 [INFO] [stdout] | [INFO] [stdout] 30 | fn get_char_freq(c: char) -> f32 { [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function is never used: `freq_score` [INFO] [stdout] --> src/crypto/xor.rs:62:4 [INFO] [stdout] | [INFO] [stdout] 62 | fn freq_score(str: &str) -> f32 { [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function is never used: `xor_hex` [INFO] [stdout] --> src/crypto/xor_hex.rs:4:8 [INFO] [stdout] | [INFO] [stdout] 4 | pub fn xor_hex(a: &str, b: &str) -> String { [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function is never used: `hex_to_vecu8` [INFO] [stdout] --> src/crypto/mod.rs:9:10 [INFO] [stdout] | [INFO] [stdout] 9 | pub fn hex_to_vecu8(hex: &str) -> Vec { [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function is never used: `hex_to_u8` [INFO] [stdout] --> src/crypto/mod.rs:19:6 [INFO] [stdout] | [INFO] [stdout] 19 | fn hex_to_u8(hex: &str) -> u8 { [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function is never used: `hex_to_decimal` [INFO] [stdout] --> src/crypto/mod.rs:33:10 [INFO] [stdout] | [INFO] [stdout] 33 | pub fn hex_to_decimal(hex: &str) -> i32 { [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function is never used: `decimal_to_bits` [INFO] [stdout] --> src/crypto/mod.rs:37:6 [INFO] [stdout] | [INFO] [stdout] 37 | fn decimal_to_bits(d: i32) -> Vec { [INFO] [stdout] | ^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function is never used: `hex_to_bits` [INFO] [stdout] --> src/crypto/mod.rs:42:10 [INFO] [stdout] | [INFO] [stdout] 42 | pub fn hex_to_bits(hex: &str) -> Vec { [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function is never used: `bits_to_hex` [INFO] [stdout] --> src/crypto/mod.rs:53:10 [INFO] [stdout] | [INFO] [stdout] 53 | pub fn bits_to_hex(bits: Vec) -> String { [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function is never used: `bits_to_decimal` [INFO] [stdout] --> src/crypto/mod.rs:62:10 [INFO] [stdout] | [INFO] [stdout] 62 | pub fn bits_to_decimal(bits: Vec) -> i32 { [INFO] [stdout] | ^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: 17 warnings emitted [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/crypto/xor.rs:21:8 [INFO] [stdout] | [INFO] [stdout] 21 | if (score > best_score) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_parens)]` on by default [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 21 - if (score > best_score) { [INFO] [stdout] 21 + if score > best_score { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `xor` [INFO] [stdout] --> src/lib.rs:6:38 [INFO] [stdout] | [INFO] [stdout] 6 | use crate::crypto::{hex_to_base64, xor, xor_hex}; [INFO] [stdout] | ^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_imports)]` on by default [INFO] [stdout] help: consider adding a `#[cfg(test)]` to the containing module [INFO] [stdout] --> src/lib.rs:4:1 [INFO] [stdout] | [INFO] [stdout] 4 | mod tests { [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: cannot borrow `letter_counts` as mutable because it is also borrowed as immutable [INFO] [stdout] --> src/crypto/xor.rs:76:7 [INFO] [stdout] | [INFO] [stdout] 75 | let v = letter_counts.get(&c).unwrap(); [INFO] [stdout] | --------------------- immutable borrow occurs here [INFO] [stdout] 76 | letter_counts.insert(c, v + 1); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^-^^^^^ [INFO] [stdout] | | | [INFO] [stdout] | | immutable borrow later used here [INFO] [stdout] | mutable borrow occurs here [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(mutable_borrow_reservation_conflict)]` on by default [INFO] [stdout] = warning: this borrowing pattern was not meant to be accepted, and may become a hard error in the future [INFO] [stdout] = note: for more information, see issue #59159 [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: 3 warnings emitted [INFO] [stdout] [INFO] [stdout] [INFO] [stderr] Finished test [unoptimized + debuginfo] target(s) in 0.93s [INFO] [stderr] Executable unittests src/lib.rs (/opt/rustwide/target/debug/deps/cryptopals-d9de9a412ba739af) [INFO] running `Command { std: "docker" "inspect" "0930eb792720936ba8f3c701983f0238a04908754bd245a428dd8bfee2ad7aef", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "0930eb792720936ba8f3c701983f0238a04908754bd245a428dd8bfee2ad7aef", kill_on_drop: false }` [INFO] [stdout] 0930eb792720936ba8f3c701983f0238a04908754bd245a428dd8bfee2ad7aef [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-27/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-27/source:/opt/rustwide/workdir:ro,Z" "-v" "/var/lib/crater-agent-workspace/cargo-home:/opt/rustwide/cargo-home:ro,Z" "-v" "/var/lib/crater-agent-workspace/rustup-home:/opt/rustwide/rustup-home:ro,Z" "-e" "SOURCE_DIR=/opt/rustwide/workdir" "-e" "CARGO_TARGET_DIR=/opt/rustwide/target" "-e" "CARGO_INCREMENTAL=0" "-e" "RUST_BACKTRACE=full" "-e" "RUSTFLAGS=--cap-lints=warn" "-e" "CARGO_HOME=/opt/rustwide/cargo-home" "-e" "RUSTUP_HOME=/opt/rustwide/rustup-home" "-w" "/opt/rustwide/workdir" "-m" "1610612736" "--user" "0:0" "--network" "none" "ghcr.io/rust-lang/crates-build-env/linux@sha256:b0c94ce3c1162fcb8e57cac5b65ec2f72eabb1eebea4fcc35e269e823f681646" "/opt/rustwide/cargo-home/bin/cargo" "+beta-2022-04-10" "test" "--frozen", kill_on_drop: false }` [INFO] [stdout] 717f172a098250e13a85a0c50ba48fb418f6ac9c6d1740dc0c7969a2a5311ca8 [INFO] running `Command { std: "docker" "start" "-a" "717f172a098250e13a85a0c50ba48fb418f6ac9c6d1740dc0c7969a2a5311ca8", kill_on_drop: false }` [INFO] [stderr] Blocking waiting for file lock on package cache [INFO] [stderr] warning: unnecessary parentheses around `if` condition [INFO] [stderr] --> src/crypto/xor.rs:21:8 [INFO] [stderr] | [INFO] [stderr] 21 | if (score > best_score) { [INFO] [stderr] | ^ ^ [INFO] [stderr] | [INFO] [stderr] = note: `#[warn(unused_parens)]` on by default [INFO] [stderr] help: remove these parentheses [INFO] [stderr] | [INFO] [stderr] 21 - if (score > best_score) { [INFO] [stderr] 21 + if score > best_score { [INFO] [stderr] | [INFO] [stderr] [INFO] [stderr] warning: cannot borrow `letter_counts` as mutable because it is also borrowed as immutable [INFO] [stderr] --> src/crypto/xor.rs:76:7 [INFO] [stderr] | [INFO] [stderr] 75 | let v = letter_counts.get(&c).unwrap(); [INFO] [stderr] | --------------------- immutable borrow occurs here [INFO] [stderr] 76 | letter_counts.insert(c, v + 1); [INFO] [stderr] | ^^^^^^^^^^^^^^^^^^^^^^^^-^^^^^ [INFO] [stderr] | | | [INFO] [stderr] | | immutable borrow later used here [INFO] [stderr] | mutable borrow occurs here [INFO] [stderr] | [INFO] [stderr] = note: `#[warn(mutable_borrow_reservation_conflict)]` on by default [INFO] [stderr] = warning: this borrowing pattern was not meant to be accepted, and may become a hard error in the future [INFO] [stderr] = note: for more information, see issue #59159 [INFO] [stderr] [INFO] [stderr] warning: function is never used: `hex_to_base64` [INFO] [stderr] --> src/crypto/hex_to_base64.rs:4:8 [INFO] [stderr] | [INFO] [stderr] 4 | pub fn hex_to_base64(hex: &str) -> String { [INFO] [stderr] | ^^^^^^^^^^^^^ [INFO] [stderr] | [INFO] [stderr] = note: `#[warn(dead_code)]` on by default [INFO] [stderr] [INFO] [stderr] warning: function is never used: `pad_bits` [INFO] [stderr] --> src/crypto/hex_to_base64.rs:22:4 [INFO] [stderr] | [INFO] [stderr] 22 | fn pad_bits(bits: Vec) -> Vec { [INFO] [stderr] | ^^^^^^^^ [INFO] [stderr] [INFO] [stderr] warning: function is never used: `bits_to_base64` [INFO] [stderr] --> src/crypto/hex_to_base64.rs:31:4 [INFO] [stderr] | [INFO] [stderr] 31 | fn bits_to_base64(bits: Vec) -> char { [INFO] [stderr] | ^^^^^^^^^^^^^^ [INFO] [stderr] [INFO] [stderr] warning: function is never used: `xor` [INFO] [stderr] --> src/crypto/xor.rs:4:8 [INFO] [stderr] | [INFO] [stderr] 4 | pub fn xor(hexed_input: &str, c: char) -> String { [INFO] [stderr] | ^^^ [INFO] [stderr] [INFO] [stderr] warning: function is never used: `decode_fixed_xor` [INFO] [stderr] --> src/crypto/xor.rs:14:8 [INFO] [stderr] | [INFO] [stderr] 14 | pub fn decode_fixed_xor(hexed_input: &str) -> String { [INFO] [stderr] | ^^^^^^^^^^^^^^^^ [INFO] [stderr] [INFO] [stderr] warning: function is never used: `get_char_freq` [INFO] [stderr] --> src/crypto/xor.rs:30:4 [INFO] [stderr] | [INFO] [stderr] 30 | fn get_char_freq(c: char) -> f32 { [INFO] [stderr] | ^^^^^^^^^^^^^ [INFO] [stderr] [INFO] [stderr] warning: function is never used: `freq_score` [INFO] [stderr] --> src/crypto/xor.rs:62:4 [INFO] [stderr] | [INFO] [stderr] 62 | fn freq_score(str: &str) -> f32 { [INFO] [stderr] | ^^^^^^^^^^ [INFO] [stderr] [INFO] [stderr] warning: function is never used: `xor_hex` [INFO] [stderr] --> src/crypto/xor_hex.rs:4:8 [INFO] [stderr] | [INFO] [stderr] 4 | pub fn xor_hex(a: &str, b: &str) -> String { [INFO] [stderr] | ^^^^^^^ [INFO] [stderr] [INFO] [stderr] warning: function is never used: `hex_to_vecu8` [INFO] [stderr] --> src/crypto/mod.rs:9:10 [INFO] [stderr] | [INFO] [stderr] 9 | pub fn hex_to_vecu8(hex: &str) -> Vec { [INFO] [stderr] | ^^^^^^^^^^^^ [INFO] [stderr] [INFO] [stderr] warning: function is never used: `hex_to_u8` [INFO] [stderr] --> src/crypto/mod.rs:19:6 [INFO] [stderr] | [INFO] [stderr] 19 | fn hex_to_u8(hex: &str) -> u8 { [INFO] [stderr] | ^^^^^^^^^ [INFO] [stderr] [INFO] [stderr] warning: function is never used: `hex_to_decimal` [INFO] [stderr] --> src/crypto/mod.rs:33:10 [INFO] [stderr] | [INFO] [stderr] 33 | pub fn hex_to_decimal(hex: &str) -> i32 { [INFO] [stderr] | ^^^^^^^^^^^^^^ [INFO] [stderr] [INFO] [stderr] warning: function is never used: `decimal_to_bits` [INFO] [stderr] --> src/crypto/mod.rs:37:6 [INFO] [stderr] | [INFO] [stderr] 37 | fn decimal_to_bits(d: i32) -> Vec { [INFO] [stderr] | ^^^^^^^^^^^^^^^ [INFO] [stderr] [INFO] [stderr] warning: function is never used: `hex_to_bits` [INFO] [stderr] --> src/crypto/mod.rs:42:10 [INFO] [stderr] | [INFO] [stderr] 42 | pub fn hex_to_bits(hex: &str) -> Vec { [INFO] [stderr] | ^^^^^^^^^^^ [INFO] [stderr] [INFO] [stderr] warning: function is never used: `bits_to_hex` [INFO] [stderr] --> src/crypto/mod.rs:53:10 [INFO] [stderr] | [INFO] [stderr] 53 | pub fn bits_to_hex(bits: Vec) -> String { [INFO] [stderr] | ^^^^^^^^^^^ [INFO] [stderr] [INFO] [stderr] warning: function is never used: `bits_to_decimal` [INFO] [stderr] --> src/crypto/mod.rs:62:10 [INFO] [stderr] | [INFO] [stderr] 62 | pub fn bits_to_decimal(bits: Vec) -> i32 { [INFO] [stderr] | ^^^^^^^^^^^^^^^ [INFO] [stderr] [INFO] [stderr] warning: `cryptopals` (lib) generated 17 warnings [INFO] [stderr] warning: unused import: `xor` [INFO] [stderr] --> src/lib.rs:6:38 [INFO] [stderr] | [INFO] [stderr] 6 | use crate::crypto::{hex_to_base64, xor, xor_hex}; [INFO] [stderr] | ^^^ [INFO] [stderr] | [INFO] [stderr] = note: `#[warn(unused_imports)]` on by default [INFO] [stderr] help: consider adding a `#[cfg(test)]` to the containing module [INFO] [stderr] --> src/lib.rs:4:1 [INFO] [stderr] | [INFO] [stderr] 4 | mod tests { [INFO] [stderr] | ^^^^^^^^^ [INFO] [stderr] [INFO] [stderr] warning: `cryptopals` (lib test) generated 3 warnings (2 duplicates) [INFO] [stderr] Finished test [unoptimized + debuginfo] target(s) in 0.12s [INFO] [stderr] Running unittests src/lib.rs (/opt/rustwide/target/debug/deps/cryptopals-d9de9a412ba739af) [INFO] [stdout] [INFO] [stdout] running 10 tests [INFO] [stdout] test crypto::hex_to_base64::tests::test_hex_to_bits ... ok [INFO] [stdout] test crypto::tests::test_bits_to_decimal_6 ... ok [INFO] [stdout] test crypto::hex_to_base64::tests::test_pad_bits ... ok [INFO] [stdout] test crypto::tests::test_bits_to_decimal_8 ... ok [INFO] [stdout] test crypto::tests::test_hex_to_decimal ... ok [INFO] [stdout] test tests::test_hex_to_vecu8 ... ok [INFO] [stdout] test tests::test_xor_hex ... ok [INFO] [stdout] test tests::test_hex_to_base64_simple ... ok [INFO] [stdout] test tests::test_hex_to_base64 ... ok [INFO] [stderr] Doc-tests cryptopals [INFO] [stdout] test crypto::xor::tests::test_decode ... ok [INFO] [stdout] [INFO] [stdout] test result: ok. 10 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out; finished in 0.02s [INFO] [stdout] [INFO] [stderr] warning: unnecessary parentheses around `if` condition [INFO] [stderr] --> /opt/rustwide/workdir/src/crypto/xor.rs:21:8 [INFO] [stderr] | [INFO] [stderr] 21 | if (score > best_score) { [INFO] [stderr] | ^ ^ [INFO] [stderr] | [INFO] [stderr] = note: `#[warn(unused_parens)]` on by default [INFO] [stderr] help: remove these parentheses [INFO] [stderr] | [INFO] [stderr] 21 - if (score > best_score) { [INFO] [stderr] 21 + if score > best_score { [INFO] [stderr] | [INFO] [stderr] [INFO] [stderr] warning: 1 warning emitted [INFO] [stderr] [INFO] [stdout] [INFO] [stdout] running 0 tests [INFO] [stdout] [INFO] [stdout] test result: ok. 0 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out; finished in 0.00s [INFO] [stdout] [INFO] running `Command { std: "docker" "inspect" "717f172a098250e13a85a0c50ba48fb418f6ac9c6d1740dc0c7969a2a5311ca8", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "717f172a098250e13a85a0c50ba48fb418f6ac9c6d1740dc0c7969a2a5311ca8", kill_on_drop: false }` [INFO] [stdout] 717f172a098250e13a85a0c50ba48fb418f6ac9c6d1740dc0c7969a2a5311ca8