[INFO] cloning repository https://github.com/sanarberkebayram/heap-vs-stack [INFO] running `Command { std: "git" "-c" "credential.helper=" "-c" "credential.helper=/workspace/cargo-home/bin/git-credential-null" "clone" "--bare" "https://github.com/sanarberkebayram/heap-vs-stack" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Fsanarberkebayram%2Fheap-vs-stack", kill_on_drop: false }` [INFO] [stderr] Cloning into bare repository '/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Fsanarberkebayram%2Fheap-vs-stack'... [INFO] running `Command { std: "git" "rev-parse" "HEAD", kill_on_drop: false }` [INFO] [stdout] 5665ea10ac97f021138882176b045d07e766b1d1 [INFO] checking sanarberkebayram/heap-vs-stack against try#93086cfebfccb79083c59d0d3b2052944bba643c for pr-146440-1 [INFO] running `Command { std: "git" "clone" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Fsanarberkebayram%2Fheap-vs-stack" "/workspace/builds/worker-2-tc2/source", kill_on_drop: false }` [INFO] [stderr] Cloning into '/workspace/builds/worker-2-tc2/source'... [INFO] [stderr] done. [INFO] started tweaking git repo https://github.com/sanarberkebayram/heap-vs-stack [INFO] finished tweaking git repo https://github.com/sanarberkebayram/heap-vs-stack [INFO] tweaked toml for git repo https://github.com/sanarberkebayram/heap-vs-stack written to /workspace/builds/worker-2-tc2/source/Cargo.toml [INFO] validating manifest of git repo https://github.com/sanarberkebayram/heap-vs-stack on toolchain 93086cfebfccb79083c59d0d3b2052944bba643c [INFO] running `Command { std: CARGO_HOME="/workspace/cargo-home" RUSTUP_HOME="/workspace/rustup-home" "/workspace/cargo-home/bin/cargo" "+93086cfebfccb79083c59d0d3b2052944bba643c" "metadata" "--manifest-path" "Cargo.toml" "--no-deps", kill_on_drop: false }` [INFO] crate git repo https://github.com/sanarberkebayram/heap-vs-stack already has a lockfile, it will not be regenerated [INFO] running `Command { std: CARGO_HOME="/workspace/cargo-home" RUSTUP_HOME="/workspace/rustup-home" "/workspace/cargo-home/bin/cargo" "+93086cfebfccb79083c59d0d3b2052944bba643c" "fetch" "--manifest-path" "Cargo.toml", kill_on_drop: false }` [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-2-tc2/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-2-tc2/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:d429b63d4308055ea97f60fb1d3dfca48854a00942f1bd2ad806beaf015945ec" "/opt/rustwide/cargo-home/bin/cargo" "+93086cfebfccb79083c59d0d3b2052944bba643c" "metadata" "--no-deps" "--format-version=1", kill_on_drop: false }` [INFO] [stdout] 5063a8408fff5d9d34c7566ddaee71879c6c8aa66c15ed88aa1de76489b2ad42 [INFO] running `Command { std: "docker" "start" "-a" "5063a8408fff5d9d34c7566ddaee71879c6c8aa66c15ed88aa1de76489b2ad42", kill_on_drop: false }` [INFO] running `Command { std: "docker" "inspect" "5063a8408fff5d9d34c7566ddaee71879c6c8aa66c15ed88aa1de76489b2ad42", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "5063a8408fff5d9d34c7566ddaee71879c6c8aa66c15ed88aa1de76489b2ad42", kill_on_drop: false }` [INFO] [stdout] 5063a8408fff5d9d34c7566ddaee71879c6c8aa66c15ed88aa1de76489b2ad42 [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-2-tc2/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-2-tc2/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=forbid" "-e" "RUSTDOCFLAGS=--cap-lints=forbid" "-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:d429b63d4308055ea97f60fb1d3dfca48854a00942f1bd2ad806beaf015945ec" "/opt/rustwide/cargo-home/bin/cargo" "+93086cfebfccb79083c59d0d3b2052944bba643c" "check" "--frozen" "--all" "--all-targets" "--message-format=json", kill_on_drop: false }` [INFO] [stdout] baec6b903a8f4e537ea84a98fd07cbc429e861564bb89e427ece66b8dcd038ae [INFO] running `Command { std: "docker" "start" "-a" "baec6b903a8f4e537ea84a98fd07cbc429e861564bb89e427ece66b8dcd038ae", kill_on_drop: false }` [INFO] [stderr] Compiling proc-macro2 v1.0.101 [INFO] [stderr] Compiling serde_json v1.0.143 [INFO] [stderr] Compiling libc v0.2.175 [INFO] [stderr] Checking cfg-if v1.0.3 [INFO] [stderr] Checking anstyle v1.0.11 [INFO] [stderr] Checking clap_lex v0.7.5 [INFO] [stderr] Checking regex-syntax v0.8.6 [INFO] [stderr] Checking itertools v0.10.5 [INFO] [stderr] Checking heap_vs_stack v0.1.0 (/opt/rustwide/workdir) [INFO] [stderr] Checking half v2.6.0 [INFO] [stdout] warning: unused imports: `ecommerce_heap::heap_test` and `ecommerce_stack::stack_test` [INFO] [stdout] --> src/lib.rs:1:13 [INFO] [stdout] | [INFO] [stdout] 1 | use crate::{ecommerce_heap::heap_test, ecommerce_stack::stack_test}; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^ ^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_imports)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable does not need to be mutable [INFO] [stdout] --> src/ecommerce_stack.rs:126:9 [INFO] [stdout] | [INFO] [stdout] 126 | let mut laptop = Product::new("Laptop", 15000.0, NoDiscount); [INFO] [stdout] | ----^^^^^^ [INFO] [stdout] | | [INFO] [stdout] | help: remove this `mut` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_mut)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable does not need to be mutable [INFO] [stdout] --> src/ecommerce_stack.rs:127:9 [INFO] [stdout] | [INFO] [stdout] 127 | let mut mouse = Product::new("Gaming Mouse", 1200.0, NoDiscount); [INFO] [stdout] | ----^^^^^ [INFO] [stdout] | | [INFO] [stdout] | help: remove this `mut` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable does not need to be mutable [INFO] [stdout] --> src/ecommerce_stack.rs:128:9 [INFO] [stdout] | [INFO] [stdout] 128 | let mut keyboard = Product::new("Mechanical Keyboard", 800.0, NoDiscount); [INFO] [stdout] | ----^^^^^^^^ [INFO] [stdout] | | [INFO] [stdout] | help: remove this `mut` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: trait `ecommerce_stack::DiscountStrategy` is more private than the item `ecommerce_stack::Product` [INFO] [stdout] --> src/ecommerce_stack.rs:43:1 [INFO] [stdout] | [INFO] [stdout] 43 | pub struct Product { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ struct `ecommerce_stack::Product` is reachable at visibility `pub` [INFO] [stdout] | [INFO] [stdout] note: but trait `ecommerce_stack::DiscountStrategy` is only usable at visibility `pub(self)` [INFO] [stdout] --> src/ecommerce_stack.rs:1:1 [INFO] [stdout] | [INFO] [stdout] 1 | trait DiscountStrategy { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] = note: `#[warn(private_bounds)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: trait `ecommerce_stack::DiscountStrategy` is more private than the item `ecommerce_stack::Product` [INFO] [stdout] --> src/ecommerce_stack.rs:49:1 [INFO] [stdout] | [INFO] [stdout] 49 | impl Product { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ implementation `ecommerce_stack::Product` is reachable at visibility `pub` [INFO] [stdout] | [INFO] [stdout] note: but trait `ecommerce_stack::DiscountStrategy` is only usable at visibility `pub(self)` [INFO] [stdout] --> src/ecommerce_stack.rs:1:1 [INFO] [stdout] | [INFO] [stdout] 1 | trait DiscountStrategy { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: trait `ecommerce_stack::ProductComponent` is more private than the item `ecommerce_stack::ProductBundle` [INFO] [stdout] --> src/ecommerce_stack.rs:83:1 [INFO] [stdout] | [INFO] [stdout] 83 | pub struct ProductBundle { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ struct `ecommerce_stack::ProductBundle` is reachable at visibility `pub` [INFO] [stdout] | [INFO] [stdout] note: but trait `ecommerce_stack::ProductComponent` is only usable at visibility `pub(self)` [INFO] [stdout] --> src/ecommerce_stack.rs:37:1 [INFO] [stdout] | [INFO] [stdout] 37 | trait ProductComponent { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: trait `ecommerce_stack::DiscountStrategy` is more private than the item `ecommerce_stack::ProductBundle` [INFO] [stdout] --> src/ecommerce_stack.rs:83:1 [INFO] [stdout] | [INFO] [stdout] 83 | pub struct ProductBundle { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ struct `ecommerce_stack::ProductBundle` is reachable at visibility `pub` [INFO] [stdout] | [INFO] [stdout] note: but trait `ecommerce_stack::DiscountStrategy` is only usable at visibility `pub(self)` [INFO] [stdout] --> src/ecommerce_stack.rs:1:1 [INFO] [stdout] | [INFO] [stdout] 1 | trait DiscountStrategy { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: trait `ecommerce_stack::ProductComponent` is more private than the item `ecommerce_stack::ProductBundle` [INFO] [stdout] --> src/ecommerce_stack.rs:89:1 [INFO] [stdout] | [INFO] [stdout] 89 | impl ProductBundle { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ implementation `ecommerce_stack::ProductBundle` is reachable at visibility `pub` [INFO] [stdout] | [INFO] [stdout] note: but trait `ecommerce_stack::ProductComponent` is only usable at visibility `pub(self)` [INFO] [stdout] --> src/ecommerce_stack.rs:37:1 [INFO] [stdout] | [INFO] [stdout] 37 | trait ProductComponent { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: trait `ecommerce_stack::DiscountStrategy` is more private than the item `ecommerce_stack::ProductBundle` [INFO] [stdout] --> src/ecommerce_stack.rs:89:1 [INFO] [stdout] | [INFO] [stdout] 89 | impl ProductBundle { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ implementation `ecommerce_stack::ProductBundle` is reachable at visibility `pub` [INFO] [stdout] | [INFO] [stdout] note: but trait `ecommerce_stack::DiscountStrategy` is only usable at visibility `pub(self)` [INFO] [stdout] --> src/ecommerce_stack.rs:1:1 [INFO] [stdout] | [INFO] [stdout] 1 | trait DiscountStrategy { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: trait `ecommerce_stack::DiscountStrategy` is more private than the item `ecommerce_stack::ProductBundle::::set_discount_strategy` [INFO] [stdout] --> src/ecommerce_stack.rs:116:5 [INFO] [stdout] | [INFO] [stdout] 116 | pub fn set_discount_strategy(self, strategy: T) -> ProductBundle { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ method `ecommerce_stack::ProductBundle::::set_discount_strategy` is reachable at visibility `pub` [INFO] [stdout] | [INFO] [stdout] note: but trait `ecommerce_stack::DiscountStrategy` is only usable at visibility `pub(self)` [INFO] [stdout] --> src/ecommerce_stack.rs:1:1 [INFO] [stdout] | [INFO] [stdout] 1 | trait DiscountStrategy { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error: struct `FixedDiscount` is never constructed [INFO] [stdout] --> src/ecommerce_heap.rs:10:12 [INFO] [stdout] | [INFO] [stdout] 10 | pub struct FixedDiscount(f64); [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: this `pub` struct has private fields, no public constructor, and is not otherwise reachable through the external API, so consider providing a public constructor or removing it [INFO] [stdout] = note: `#[deny(unused_unconstructable_pub_structs)]` (part of `#[deny(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: trait `PriceObserver` is never used [INFO] [stdout] --> src/ecommerce_heap.rs:136:7 [INFO] [stdout] | [INFO] [stdout] 136 | trait PriceObserver { [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(dead_code)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `PriceDisplayObserver` is never constructed [INFO] [stdout] --> src/ecommerce_heap.rs:140:8 [INFO] [stdout] | [INFO] [stdout] 140 | struct PriceDisplayObserver; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `ObservableProduct` is never constructed [INFO] [stdout] --> src/ecommerce_heap.rs:148:8 [INFO] [stdout] | [INFO] [stdout] 148 | struct ObservableProduct<'a> { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: associated items `new`, `add_observer`, and `notify` are never used [INFO] [stdout] --> src/ecommerce_heap.rs:154:8 [INFO] [stdout] | [INFO] [stdout] 153 | impl<'a> ObservableProduct<'a> { [INFO] [stdout] | ------------------------------ associated items in this implementation [INFO] [stdout] 154 | fn new(name: &'a str, price: f64, strategy: &'static dyn DiscountStrategy) -> Self { [INFO] [stdout] | ^^^ [INFO] [stdout] ... [INFO] [stdout] 160 | fn add_observer(&self, observer: &'a dyn PriceObserver) { [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 163 | fn notify(&self) { [INFO] [stdout] | ^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: static `FIXED_2000` is never used [INFO] [stdout] --> src/ecommerce_heap.rs:187:8 [INFO] [stdout] | [INFO] [stdout] 187 | static FIXED_2000: FixedDiscount = FixedDiscount(2000.0); [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: static `FIXED_200` is never used [INFO] [stdout] --> src/ecommerce_heap.rs:188:8 [INFO] [stdout] | [INFO] [stdout] 188 | static FIXED_200: FixedDiscount = FixedDiscount(200.0); [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: method `set_discount_strategy` is never used [INFO] [stdout] --> src/ecommerce_stack.rs:40:8 [INFO] [stdout] | [INFO] [stdout] 37 | trait ProductComponent { [INFO] [stdout] | ---------------- method in this trait [INFO] [stdout] ... [INFO] [stdout] 40 | fn set_discount_strategy(&mut self); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: method `set_strategy` is never used [INFO] [stdout] --> src/ecommerce_stack.rs:58:8 [INFO] [stdout] | [INFO] [stdout] 49 | impl Product { [INFO] [stdout] | ------------------------------------ method in this implementation [INFO] [stdout] ... [INFO] [stdout] 58 | fn set_strategy(self, strategy: T) -> Product { [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stderr] error: could not compile `heap_vs_stack` (lib) due to 1 previous error; 19 warnings emitted [INFO] [stderr] warning: build failed, waiting for other jobs to finish... [INFO] running `Command { std: "docker" "inspect" "baec6b903a8f4e537ea84a98fd07cbc429e861564bb89e427ece66b8dcd038ae", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "baec6b903a8f4e537ea84a98fd07cbc429e861564bb89e427ece66b8dcd038ae", kill_on_drop: false }` [INFO] [stdout] baec6b903a8f4e537ea84a98fd07cbc429e861564bb89e427ece66b8dcd038ae