[INFO] cloning repository https://github.com/ColdRain-Moro/compiler-learning [INFO] running `Command { std: "git" "-c" "credential.helper=" "-c" "credential.helper=/workspace/cargo-home/bin/git-credential-null" "clone" "--bare" "https://github.com/ColdRain-Moro/compiler-learning" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2FColdRain-Moro%2Fcompiler-learning", kill_on_drop: false }` [INFO] [stderr] Cloning into bare repository '/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2FColdRain-Moro%2Fcompiler-learning'... [INFO] running `Command { std: "git" "rev-parse" "HEAD", kill_on_drop: false }` [INFO] [stdout] 5e439b8c2a16d04262ae0d0aecc518c96cd25a35 [INFO] checking ColdRain-Moro/compiler-learning/5e439b8c2a16d04262ae0d0aecc518c96cd25a35 against try#ccf408f4326a858c00dd845a64a86b16f360a801 for pr-129466-2 [INFO] running `Command { std: "git" "clone" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2FColdRain-Moro%2Fcompiler-learning" "/workspace/builds/worker-0-tc2/source", kill_on_drop: false }` [INFO] [stderr] Cloning into '/workspace/builds/worker-0-tc2/source'... [INFO] [stderr] done. [INFO] validating manifest of git repo https://github.com/ColdRain-Moro/compiler-learning on toolchain ccf408f4326a858c00dd845a64a86b16f360a801 [INFO] running `Command { std: CARGO_HOME="/workspace/cargo-home" RUSTUP_HOME="/workspace/rustup-home" "/workspace/cargo-home/bin/cargo" "+ccf408f4326a858c00dd845a64a86b16f360a801" "metadata" "--manifest-path" "Cargo.toml" "--no-deps", kill_on_drop: false }` [INFO] started tweaking git repo https://github.com/ColdRain-Moro/compiler-learning [INFO] finished tweaking git repo https://github.com/ColdRain-Moro/compiler-learning [INFO] tweaked toml for git repo https://github.com/ColdRain-Moro/compiler-learning written to /workspace/builds/worker-0-tc2/source/Cargo.toml [INFO] crate git repo https://github.com/ColdRain-Moro/compiler-learning 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" "+ccf408f4326a858c00dd845a64a86b16f360a801" "fetch" "--manifest-path" "Cargo.toml", kill_on_drop: false }` [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-0-tc2/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-0-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:ceb6ea022f8a89cebbe621bb4987e73a935bd40dfbb726f832cfff4742a5b95a" "/opt/rustwide/cargo-home/bin/cargo" "+ccf408f4326a858c00dd845a64a86b16f360a801" "metadata" "--no-deps" "--format-version=1", kill_on_drop: false }` [INFO] [stdout] 7fa6daccc7c9375249ece72f53fbcfb6e7b33ef76cc0305c698eb0c5eb48b0ea [INFO] running `Command { std: "docker" "start" "-a" "7fa6daccc7c9375249ece72f53fbcfb6e7b33ef76cc0305c698eb0c5eb48b0ea", kill_on_drop: false }` [INFO] running `Command { std: "docker" "inspect" "7fa6daccc7c9375249ece72f53fbcfb6e7b33ef76cc0305c698eb0c5eb48b0ea", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "7fa6daccc7c9375249ece72f53fbcfb6e7b33ef76cc0305c698eb0c5eb48b0ea", kill_on_drop: false }` [INFO] [stdout] 7fa6daccc7c9375249ece72f53fbcfb6e7b33ef76cc0305c698eb0c5eb48b0ea [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-0-tc2/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-0-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:ceb6ea022f8a89cebbe621bb4987e73a935bd40dfbb726f832cfff4742a5b95a" "/opt/rustwide/cargo-home/bin/cargo" "+ccf408f4326a858c00dd845a64a86b16f360a801" "check" "--frozen" "--all" "--all-targets" "--message-format=json", kill_on_drop: false }` [INFO] [stdout] d0402468320ae88023b86402ba67793fdda14b3d744f05fd94ccfa491fab3780 [INFO] running `Command { std: "docker" "start" "-a" "d0402468320ae88023b86402ba67793fdda14b3d744f05fd94ccfa491fab3780", kill_on_drop: false }` [INFO] [stderr] Copying to /tmp/fixit [INFO] [stderr] Running `cargo fix --edition` [INFO] [stderr] Migrating Cargo.toml from 2021 edition to 2024 [INFO] [stderr] Compiling libc v0.2.139 [INFO] [stderr] Compiling parking_lot_core v0.9.6 [INFO] [stderr] Compiling log v0.4.17 [INFO] [stderr] Compiling smallvec v1.10.0 [INFO] [stderr] Compiling scopeguard v1.1.0 [INFO] [stderr] Compiling tiny-keccak v2.0.2 [INFO] [stderr] Compiling regex-syntax v0.6.28 [INFO] [stderr] Compiling siphasher v0.3.10 [INFO] [stderr] Compiling hashbrown v0.12.3 [INFO] [stderr] Compiling either v1.8.0 [INFO] [stderr] Compiling bit-vec v0.6.3 [INFO] [stderr] Compiling lock_api v0.4.9 [INFO] [stderr] Compiling indexmap v1.9.2 [INFO] [stderr] Compiling memchr v2.5.0 [INFO] [stderr] Compiling fixedbitset v0.4.2 [INFO] [stderr] Compiling once_cell v1.17.0 [INFO] [stderr] Compiling new_debug_unreachable v1.0.4 [INFO] [stderr] Compiling precomputed-hash v0.1.1 [INFO] [stderr] Compiling phf_shared v0.10.0 [INFO] [stderr] Compiling bit-set v0.5.3 [INFO] [stderr] Compiling itertools v0.10.5 [INFO] [stderr] Compiling pico-args v0.4.2 [INFO] [stderr] Compiling diff v0.1.13 [INFO] [stderr] Compiling unicode-xid v0.2.4 [INFO] [stderr] Checking aho-corasick v0.7.20 [INFO] [stderr] Checking atty v0.2.14 [INFO] [stderr] Checking colored v2.0.0 [INFO] [stderr] Compiling ena v0.14.0 [INFO] [stderr] Checking key-node-list v0.0.5 [INFO] [stderr] Checking koopa v0.0.6 [INFO] [stderr] Compiling petgraph v0.6.2 [INFO] [stderr] Compiling dirs-sys-next v0.1.2 [INFO] [stderr] Compiling dirs-next v2.0.0 [INFO] [stderr] Compiling parking_lot v0.12.1 [INFO] [stderr] Compiling term v0.7.0 [INFO] [stderr] Compiling string_cache v0.8.4 [INFO] [stderr] Compiling ascii-canvas v3.0.0 [INFO] [stderr] Compiling regex v1.7.1 [INFO] [stderr] Checking lalrpop-util v0.19.8 [INFO] [stderr] Compiling lalrpop v0.19.8 [INFO] [stderr] Compiling compiler-learning v0.1.0 (/tmp/fixit) [INFO] [stderr] Migrating build.rs from 2021 edition to 2024 [INFO] [stderr] Migrating src/main.rs from 2021 edition to 2024 [INFO] [stderr] warning: failed to automatically apply fixes suggested by rustc to crate `compiler_learning` [INFO] [stderr] [INFO] [stderr] after fixes were automatically applied the compiler reported errors within these files: [INFO] [stderr] [INFO] [stderr] * src/backend/gen.rs [INFO] [stderr] * src/frontend/context.rs [INFO] [stderr] * src/frontend/gen.rs [INFO] [stderr] [INFO] [stderr] This likely indicates a bug in either rustc or cargo itself, [INFO] [stderr] and we would appreciate a bug report! You're likely to see [INFO] [stderr] a number of compiler warnings after this message which cargo [INFO] [stderr] attempted to fix but failed. If you could open an issue at [INFO] [stderr] https://github.com/rust-lang/rust/issues [INFO] [stderr] quoting the full output of this command we'd be very appreciative! [INFO] [stderr] Note that you may be able to make some more progress in the near-term [INFO] [stderr] fixing code with the `--broken-code` flag [INFO] [stderr] [INFO] [stderr] The following errors were reported: [INFO] [stderr] error[E0658]: fragment specifier `expr_2021` is unstable [INFO] [stderr] --> src/frontend/context.rs:18:4 [INFO] [stderr] | [INFO] [stderr] 18 | ($scopes:expr_2021) => { [INFO] [stderr] | ^^^^^^^^^^^^^^^^^ [INFO] [stderr] | [INFO] [stderr] = note: see issue #123742 for more information [INFO] [stderr] = help: add `#![feature(expr_fragment_specifier_2024)]` to the crate attributes to enable [INFO] [stderr] = note: this compiler was built on 2024-09-17; consider upgrading it if it is out of date [INFO] [stderr] [INFO] [stderr] error[E0658]: fragment specifier `expr_2021` is unstable [INFO] [stderr] --> src/frontend/context.rs:26:4 [INFO] [stderr] | [INFO] [stderr] 26 | ($scopes:expr_2021) => { [INFO] [stdout] warning: `gen` is a keyword in the 2024 edition [INFO] [stdout] --> src/main.rs:7:21 [INFO] [stdout] | [INFO] [stdout] 7 | use crate::backend::gen::Gen; [INFO] [stdout] | ^^^ help: you can use a raw identifier to stay compatible: `r#gen` [INFO] [stdout] | [INFO] [stdout] = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024! [INFO] [stdout] = note: for more information, see issue #49716 [INFO] [stdout] = note: `--force-warn keyword-idents-2024` implied by `--force-warn rust-2024-compatibility` [INFO] [stdout] [INFO] [stdout] [INFO] [stderr] | ^^^^^^^^^^^^^^^^^ [INFO] [stdout] warning: `gen` is a keyword in the 2024 edition [INFO] [stdout] --> src/main.rs:9:22 [INFO] [stdout] | [INFO] [stdout] 9 | use crate::frontend::gen::compile_koopa; [INFO] [stdout] | ^^^ help: you can use a raw identifier to stay compatible: `r#gen` [INFO] [stdout] | [INFO] [stdout] = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024! [INFO] [stdout] = note: for more information, see issue #49716 [INFO] [stdout] [INFO] [stdout] [INFO] [stderr] | [INFO] [stderr] = note: see issue #123742 for more information [INFO] [stderr] = help: add `#![feature(expr_fragment_specifier_2024)]` to the crate attributes to enable [INFO] [stderr] = note: this compiler was built on 2024-09-17; consider upgrading it if it is out of date [INFO] [stderr] [INFO] [stderr] warning: unused variable: `codes` [INFO] [stderr] --> src/backend/gen.rs:7:24 [INFO] [stderr] | [INFO] [stderr] 7 | fn generate(&self, codes: &mut Vec) { [INFO] [stderr] | ^^^^^ help: if this is intentional, prefix it with an underscore: `_codes` [INFO] [stderr] | [INFO] [stderr] = note: `#[warn(unused_variables)]` on by default [INFO] [stderr] [INFO] [stderr] warning: unused variable: `codes` [INFO] [stderr] --> src/backend/gen.rs:11:36 [INFO] [stderr] | [INFO] [stderr] 11 | fn visit_with_func_data(&self, codes: &mut Vec, func_data: &FunctionData) { [INFO] [stderr] | ^^^^^ help: if this is intentional, prefix it with an underscore: `_codes` [INFO] [stderr] [INFO] [stderr] warning: unused variable: `func_data` [INFO] [stderr] --> src/backend/gen.rs:11:61 [INFO] [stderr] | [INFO] [stderr] 11 | fn visit_with_func_data(&self, codes: &mut Vec, func_data: &FunctionData) { [INFO] [stderr] | ^^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_func_data` [INFO] [stderr] [INFO] [stderr] warning: unused variable: `is_void` [INFO] [stderr] --> src/frontend/gen.rs:630:33 [INFO] [stderr] | [INFO] [stderr] 630 | let (params_ty, is_void) = { [INFO] [stderr] | ^^^^^^^ help: if this is intentional, prefix it with an underscore: `_is_void` [INFO] [stderr] [INFO] [stderr] error: aborting due to 2 previous errors; 4 warnings emitted [INFO] [stderr] [INFO] [stderr] For more information about this error, try `rustc --explain E0658`. [INFO] [stderr] Original diagnostics will follow. [INFO] [stderr] [INFO] [stdout] warning: `gen` is a keyword in the 2024 edition [INFO] [stdout] --> src/backend/mod.rs:1:9 [INFO] [stdout] | [INFO] [stdout] 1 | pub mod gen; [INFO] [stdout] | ^^^ help: you can use a raw identifier to stay compatible: `r#gen` [INFO] [stdout] | [INFO] [stdout] = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024! [INFO] [stdout] = note: for more information, see issue #49716 [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: `gen` is a keyword in the 2024 edition [INFO] [stdout] --> src/frontend/mod.rs:5:9 [INFO] [stdout] | [INFO] [stdout] 5 | pub mod gen; [INFO] [stdout] | ^^^ help: you can use a raw identifier to stay compatible: `r#gen` [INFO] [stdout] | [INFO] [stdout] = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024! [INFO] [stdout] = note: for more information, see issue #49716 [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: `gen` is a keyword in the 2024 edition [INFO] [stdout] --> src/frontend/gen.rs:15:13 [INFO] [stdout] | [INFO] [stdout] 15 | let mut gen = KoopaGenerator::new(vec![]); [INFO] [stdout] | ^^^ help: you can use a raw identifier to stay compatible: `r#gen` [INFO] [stdout] | [INFO] [stdout] = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024! [INFO] [stdout] = note: for more information, see issue #49716 [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: `gen` is a keyword in the 2024 edition [INFO] [stdout] --> src/frontend/gen.rs:16:5 [INFO] [stdout] | [INFO] [stdout] 16 | gen.generate_on(&program).expect("koopa ir generation failed"); [INFO] [stdout] | ^^^ help: you can use a raw identifier to stay compatible: `r#gen` [INFO] [stdout] | [INFO] [stdout] = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024! [INFO] [stdout] = note: for more information, see issue #49716 [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: `gen` is a keyword in the 2024 edition [INFO] [stdout] --> src/frontend/gen.rs:17:29 [INFO] [stdout] | [INFO] [stdout] 17 | Ok(std::str::from_utf8(&gen.writer()).unwrap().to_string()) [INFO] [stdout] | ^^^ help: you can use a raw identifier to stay compatible: `r#gen` [INFO] [stdout] | [INFO] [stdout] = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024! [INFO] [stdout] = note: for more information, see issue #49716 [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `std::fmt::write` [INFO] [stdout] --> src/frontend/mod.rs:2:5 [INFO] [stdout] | [INFO] [stdout] 2 | use std::fmt::write; [INFO] [stdout] | ^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_imports)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `FuncFParam` [INFO] [stdout] --> src/frontend/gen.rs:5:126 [INFO] [stdout] | [INFO] [stdout] 5 | ... ConstDef, ConstExp, ConstInitVal, Decl, EqExp, Exp, FuncDef, FuncFParam, FuncFParams, FuncType, GlobalDef, InitVal, LAndExp, LOrExp, ... [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `ValueBuilder` [INFO] [stdout] --> src/frontend/context.rs:3:77 [INFO] [stdout] | [INFO] [stdout] 3 | use koopa::ir::builder::{BasicBlockBuilder, LocalBuilder, LocalInstBuilder, ValueBuilder}; [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: the `expr` fragment specifier will accept more expressions in the 2024 edition [INFO] [stdout] --> src/frontend/context.rs:18:12 [INFO] [stdout] | [INFO] [stdout] 18 | ($scopes:expr) => { [INFO] [stdout] | ^^^^ [INFO] [stdout] | [INFO] [stdout] = warning: this changes meaning in Rust 2024 [INFO] [stdout] = note: for more information, see Migration Guide [INFO] [stdout] = note: `--force-warn edition-2024-expr-fragment-specifier` implied by `--force-warn rust-2024-compatibility` [INFO] [stdout] help: to keep the existing behavior, use the `expr_2021` fragment specifier [INFO] [stdout] | [INFO] [stdout] 18 | ($scopes:expr_2021) => { [INFO] [stdout] | ~~~~~~~~~ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: the `expr` fragment specifier will accept more expressions in the 2024 edition [INFO] [stdout] --> src/frontend/context.rs:26:12 [INFO] [stdout] | [INFO] [stdout] 26 | ($scopes:expr) => { [INFO] [stdout] | ^^^^ [INFO] [stdout] | [INFO] [stdout] = warning: this changes meaning in Rust 2024 [INFO] [stdout] = note: for more information, see Migration Guide [INFO] [stdout] help: to keep the existing behavior, use the `expr_2021` fragment specifier [INFO] [stdout] | [INFO] [stdout] 26 | ($scopes:expr_2021) => { [INFO] [stdout] | ~~~~~~~~~ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `ValueKind` [INFO] [stdout] --> src/frontend/eval.rs:1:26 [INFO] [stdout] | [INFO] [stdout] 1 | use koopa::ir::{Program, ValueKind}; [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `cur_func` [INFO] [stdout] --> src/frontend/eval.rs:3:50 [INFO] [stdout] | [INFO] [stdout] 3 | use crate::frontend::context::{Context, CTValue, cur_func}; [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `codes` [INFO] [stdout] --> src/backend/gen.rs:7:24 [INFO] [stdout] | [INFO] [stdout] 7 | fn generate(&self, codes: &mut Vec) { [INFO] [stdout] | ^^^^^ help: if this is intentional, prefix it with an underscore: `_codes` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_variables)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `codes` [INFO] [stdout] --> src/backend/gen.rs:11:36 [INFO] [stdout] | [INFO] [stdout] 11 | fn visit_with_func_data(&self, codes: &mut Vec, func_data: &FunctionData) { [INFO] [stdout] | ^^^^^ help: if this is intentional, prefix it with an underscore: `_codes` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `func_data` [INFO] [stdout] --> src/backend/gen.rs:11:61 [INFO] [stdout] | [INFO] [stdout] 11 | fn visit_with_func_data(&self, codes: &mut Vec, func_data: &FunctionData) { [INFO] [stdout] | ^^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_func_data` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `is_void` [INFO] [stdout] --> src/frontend/gen.rs:630:33 [INFO] [stdout] | [INFO] [stdout] 630 | let (params_ty, is_void) = { [INFO] [stdout] | ^^^^^^^ help: if this is intentional, prefix it with an underscore: `_is_void` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: multiple variants are never constructed [INFO] [stdout] --> src/frontend/mod.rs:12:5 [INFO] [stdout] | [INFO] [stdout] 10 | pub enum Error { [INFO] [stdout] | ----- variants in this enum [INFO] [stdout] 11 | DuplicatedDef, [INFO] [stdout] 12 | InvalidVarDef, [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 16 | FailedToEval, [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] 17 | InvalidArrayLen, [INFO] [stdout] | ^^^^^^^^^^^^^^^ [INFO] [stdout] 18 | InvalidInit, [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] 19 | ArrayAssign, [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] 20 | NotInLoop, [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] 21 | RetValInVoidFunc, [INFO] [stdout] | ^^^^^^^^^^^^^^^^ [INFO] [stdout] 22 | DerefInt, [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] 23 | UseVoidValue, [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] 24 | ArgMismatch, [INFO] [stdout] 25 | NonIntCalc, [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(dead_code)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: field `entry` is never read [INFO] [stdout] --> src/frontend/context.rs:34:5 [INFO] [stdout] | [INFO] [stdout] 32 | pub struct FunctionInfo { [INFO] [stdout] | ------------ field in this struct [INFO] [stdout] 33 | func: Function, [INFO] [stdout] 34 | entry: BasicBlock, [INFO] [stdout] | ^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: methods `print` and `as_runtime` are never used [INFO] [stdout] --> src/frontend/context.rs:235:8 [INFO] [stdout] | [INFO] [stdout] 234 | impl CTValue { [INFO] [stdout] | ------------ methods in this implementation [INFO] [stdout] 235 | fn print(&self, context: &mut Context, program: &mut Program) { [INFO] [stdout] | ^^^^^ [INFO] [stdout] ... [INFO] [stdout] 244 | fn as_runtime(&self) -> Value { [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: associated function `to_triple` is never used [INFO] [stdout] --> /opt/rustwide/target/debug/build/compiler-learning-d349568f895331bc/out/sysy.rs:6362:8 [INFO] [stdout] | [INFO] [stdout] 6360 | pub trait __ToTriple<'input, > [INFO] [stdout] | ---------- associated function in this trait [INFO] [stdout] 6361 | { [INFO] [stdout] 6362 | fn to_triple(value: Self) -> Result<(usize,Token<'input>,usize), __lalrpop_util::ParseError, &'static str>>; [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: 22 warnings emitted [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: `gen` is a keyword in the 2024 edition [INFO] [stdout] --> src/main.rs:7:21 [INFO] [stdout] | [INFO] [stdout] 7 | use crate::backend::gen::Gen; [INFO] [stdout] | ^^^ help: you can use a raw identifier to stay compatible: `r#gen` [INFO] [stdout] | [INFO] [stdout] = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024! [INFO] [stdout] = note: for more information, see issue #49716 [INFO] [stdout] = note: `--force-warn keyword-idents-2024` implied by `--force-warn rust-2024-compatibility` [INFO] [stdout] [INFO] [stdout] [INFO] [stderr] warning: failed to automatically apply fixes suggested by rustc to crate `compiler_learning` [INFO] [stderr] [INFO] [stderr] after fixes were automatically applied the compiler reported errors within these files: [INFO] [stderr] [INFO] [stderr] * src/backend/gen.rs [INFO] [stderr] * src/frontend/context.rs [INFO] [stderr] * src/frontend/gen.rs [INFO] [stderr] [INFO] [stderr] This likely indicates a bug in either rustc or cargo itself, [INFO] [stderr] and we would appreciate a bug report! You're likely to see [INFO] [stderr] a number of compiler warnings after this message which cargo [INFO] [stderr] attempted to fix but failed. If you could open an issue at [INFO] [stderr] https://github.com/rust-lang/rust/issues [INFO] [stderr] quoting the full output of this command we'd be very appreciative! [INFO] [stderr] Note that you may be able to make some more progress in the near-term [INFO] [stderr] fixing code with the `--broken-code` flag [INFO] [stderr] [INFO] [stderr] The following errors were reported: [INFO] [stderr] error[E0658]: fragment specifier `expr_2021` is unstable [INFO] [stderr] --> src/frontend/context.rs:18:4 [INFO] [stderr] | [INFO] [stderr] 18 | ($scopes:expr_2021) => { [INFO] [stderr] | ^^^^^^^^^^^^^^^^^ [INFO] [stderr] | [INFO] [stderr] = note: see issue #123742 for more information [INFO] [stderr] = help: add `#![feature(expr_fragment_specifier_2024)]` to the crate attributes to enable [INFO] [stderr] = note: this compiler was built on 2024-09-17; consider upgrading it if it is out of date [INFO] [stderr] [INFO] [stderr] error[E0658]: fragment specifier `expr_2021` is unstable [INFO] [stderr] --> src/frontend/context.rs:26:4 [INFO] [stderr] | [INFO] [stderr] 26 | ($scopes:expr_2021) => { [INFO] [stderr] | ^^^^^^^^^^^^^^^^^ [INFO] [stderr] | [INFO] [stderr] = note: see issue #123742 for more information [INFO] [stderr] = help: add `#![feature(expr_fragment_specifier_2024)]` to the crate attributes to enable [INFO] [stderr] = note: this compiler was built on 2024-09-17; consider upgrading it if it is out of date [INFO] [stderr] [INFO] [stderr] warning: unused variable: `codes` [INFO] [stderr] --> src/backend/gen.rs:7:24 [INFO] [stderr] | [INFO] [stderr] 7 | fn generate(&self, codes: &mut Vec) { [INFO] [stderr] | ^^^^^ help: if this is intentional, prefix it with an underscore: `_codes` [INFO] [stderr] | [INFO] [stderr] = note: `#[warn(unused_variables)]` on by default [INFO] [stderr] [INFO] [stderr] warning: unused variable: `codes` [INFO] [stdout] warning: `gen` is a keyword in the 2024 edition [INFO] [stdout] --> src/main.rs:9:22 [INFO] [stdout] | [INFO] [stdout] 9 | use crate::frontend::gen::compile_koopa; [INFO] [stdout] | ^^^ help: you can use a raw identifier to stay compatible: `r#gen` [INFO] [stdout] | [INFO] [stdout] = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024! [INFO] [stdout] = note: for more information, see issue #49716 [INFO] [stdout] [INFO] [stdout] [INFO] [stderr] --> src/backend/gen.rs:11:36 [INFO] [stdout] warning: `gen` is a keyword in the 2024 edition [INFO] [stdout] --> src/backend/mod.rs:1:9 [INFO] [stdout] | [INFO] [stdout] 1 | pub mod gen; [INFO] [stdout] | ^^^ help: you can use a raw identifier to stay compatible: `r#gen` [INFO] [stdout] | [INFO] [stdout] = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024! [INFO] [stdout] = note: for more information, see issue #49716 [INFO] [stdout] [INFO] [stdout] [INFO] [stderr] | [INFO] [stdout] warning: `gen` is a keyword in the 2024 edition [INFO] [stdout] --> src/frontend/mod.rs:5:9 [INFO] [stdout] | [INFO] [stdout] 5 | pub mod gen; [INFO] [stdout] | ^^^ help: you can use a raw identifier to stay compatible: `r#gen` [INFO] [stdout] | [INFO] [stdout] = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024! [INFO] [stdout] = note: for more information, see issue #49716 [INFO] [stdout] [INFO] [stdout] [INFO] [stderr] 11 | fn visit_with_func_data(&self, codes: &mut Vec, func_data: &FunctionData) { [INFO] [stdout] warning: `gen` is a keyword in the 2024 edition [INFO] [stdout] --> src/frontend/gen.rs:15:13 [INFO] [stdout] | [INFO] [stdout] 15 | let mut gen = KoopaGenerator::new(vec![]); [INFO] [stdout] | ^^^ help: you can use a raw identifier to stay compatible: `r#gen` [INFO] [stdout] | [INFO] [stdout] = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024! [INFO] [stdout] = note: for more information, see issue #49716 [INFO] [stdout] [INFO] [stdout] [INFO] [stderr] | ^^^^^ help: if this is intentional, prefix it with an underscore: `_codes` [INFO] [stdout] warning: `gen` is a keyword in the 2024 edition [INFO] [stdout] --> src/frontend/gen.rs:16:5 [INFO] [stdout] | [INFO] [stdout] 16 | gen.generate_on(&program).expect("koopa ir generation failed"); [INFO] [stdout] | ^^^ help: you can use a raw identifier to stay compatible: `r#gen` [INFO] [stdout] | [INFO] [stdout] = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024! [INFO] [stdout] = note: for more information, see issue #49716 [INFO] [stdout] [INFO] [stdout] [INFO] [stderr] [INFO] [stdout] warning: `gen` is a keyword in the 2024 edition [INFO] [stdout] --> src/frontend/gen.rs:17:29 [INFO] [stdout] | [INFO] [stdout] 17 | Ok(std::str::from_utf8(&gen.writer()).unwrap().to_string()) [INFO] [stdout] | ^^^ help: you can use a raw identifier to stay compatible: `r#gen` [INFO] [stdout] | [INFO] [stdout] = warning: this is accepted in the current edition (Rust 2021) but is a hard error in Rust 2024! [INFO] [stdout] = note: for more information, see issue #49716 [INFO] [stdout] [INFO] [stdout] [INFO] [stderr] warning: unused variable: `func_data` [INFO] [stdout] warning: unused import: `std::fmt::write` [INFO] [stdout] --> src/frontend/mod.rs:2:5 [INFO] [stdout] | [INFO] [stdout] 2 | use std::fmt::write; [INFO] [stdout] | ^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_imports)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stderr] --> src/backend/gen.rs:11:61 [INFO] [stdout] warning: unused import: `FuncFParam` [INFO] [stdout] --> src/frontend/gen.rs:5:126 [INFO] [stdout] | [INFO] [stdout] 5 | ... ConstDef, ConstExp, ConstInitVal, Decl, EqExp, Exp, FuncDef, FuncFParam, FuncFParams, FuncType, GlobalDef, InitVal, LAndExp, LOrExp, ... [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stderr] | [INFO] [stdout] warning: unused import: `ValueBuilder` [INFO] [stdout] --> src/frontend/context.rs:3:77 [INFO] [stdout] | [INFO] [stdout] 3 | use koopa::ir::builder::{BasicBlockBuilder, LocalBuilder, LocalInstBuilder, ValueBuilder}; [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stderr] 11 | fn visit_with_func_data(&self, codes: &mut Vec, func_data: &FunctionData) { [INFO] [stdout] warning: the `expr` fragment specifier will accept more expressions in the 2024 edition [INFO] [stdout] --> src/frontend/context.rs:18:12 [INFO] [stdout] | [INFO] [stdout] 18 | ($scopes:expr) => { [INFO] [stdout] | ^^^^ [INFO] [stdout] | [INFO] [stdout] = warning: this changes meaning in Rust 2024 [INFO] [stdout] = note: for more information, see Migration Guide [INFO] [stdout] = note: `--force-warn edition-2024-expr-fragment-specifier` implied by `--force-warn rust-2024-compatibility` [INFO] [stdout] help: to keep the existing behavior, use the `expr_2021` fragment specifier [INFO] [stdout] | [INFO] [stdout] 18 | ($scopes:expr_2021) => { [INFO] [stdout] | ~~~~~~~~~ [INFO] [stdout] [INFO] [stdout] [INFO] [stderr] | ^^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_func_data` [INFO] [stderr] [INFO] [stderr] warning: unused variable: `is_void` [INFO] [stderr] --> src/frontend/gen.rs:630:33 [INFO] [stderr] | [INFO] [stderr] 630 | let (params_ty, is_void) = { [INFO] [stderr] | ^^^^^^^ help: if this is intentional, prefix it with an underscore: `_is_void` [INFO] [stderr] [INFO] [stderr] error: aborting due to 2 previous errors; 4 warnings emitted [INFO] [stderr] [INFO] [stderr] For more information about this error, try `rustc --explain E0658`. [INFO] [stderr] Original diagnostics will follow. [INFO] [stderr] [INFO] [stdout] warning: the `expr` fragment specifier will accept more expressions in the 2024 edition [INFO] [stdout] --> src/frontend/context.rs:26:12 [INFO] [stdout] | [INFO] [stdout] 26 | ($scopes:expr) => { [INFO] [stdout] | ^^^^ [INFO] [stdout] | [INFO] [stdout] = warning: this changes meaning in Rust 2024 [INFO] [stdout] = note: for more information, see Migration Guide [INFO] [stdout] help: to keep the existing behavior, use the `expr_2021` fragment specifier [INFO] [stdout] | [INFO] [stdout] 26 | ($scopes:expr_2021) => { [INFO] [stdout] | ~~~~~~~~~ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `ValueKind` [INFO] [stdout] --> src/frontend/eval.rs:1:26 [INFO] [stdout] | [INFO] [stdout] 1 | use koopa::ir::{Program, ValueKind}; [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `cur_func` [INFO] [stdout] --> src/frontend/eval.rs:3:50 [INFO] [stdout] | [INFO] [stdout] 3 | use crate::frontend::context::{Context, CTValue, cur_func}; [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `codes` [INFO] [stdout] --> src/backend/gen.rs:7:24 [INFO] [stdout] | [INFO] [stdout] 7 | fn generate(&self, codes: &mut Vec) { [INFO] [stdout] | ^^^^^ help: if this is intentional, prefix it with an underscore: `_codes` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_variables)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `codes` [INFO] [stdout] --> src/backend/gen.rs:11:36 [INFO] [stdout] | [INFO] [stdout] 11 | fn visit_with_func_data(&self, codes: &mut Vec, func_data: &FunctionData) { [INFO] [stdout] | ^^^^^ help: if this is intentional, prefix it with an underscore: `_codes` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `func_data` [INFO] [stdout] --> src/backend/gen.rs:11:61 [INFO] [stdout] | [INFO] [stdout] 11 | fn visit_with_func_data(&self, codes: &mut Vec, func_data: &FunctionData) { [INFO] [stdout] | ^^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_func_data` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `is_void` [INFO] [stdout] --> src/frontend/gen.rs:630:33 [INFO] [stdout] | [INFO] [stdout] 630 | let (params_ty, is_void) = { [INFO] [stdout] | ^^^^^^^ help: if this is intentional, prefix it with an underscore: `_is_void` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: multiple variants are never constructed [INFO] [stdout] --> src/frontend/mod.rs:12:5 [INFO] [stdout] | [INFO] [stdout] 10 | pub enum Error { [INFO] [stdout] | ----- variants in this enum [INFO] [stdout] 11 | DuplicatedDef, [INFO] [stdout] 12 | InvalidVarDef, [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 16 | FailedToEval, [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] 17 | InvalidArrayLen, [INFO] [stdout] | ^^^^^^^^^^^^^^^ [INFO] [stdout] 18 | InvalidInit, [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] 19 | ArrayAssign, [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] 20 | NotInLoop, [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] 21 | RetValInVoidFunc, [INFO] [stdout] | ^^^^^^^^^^^^^^^^ [INFO] [stdout] 22 | DerefInt, [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] 23 | UseVoidValue, [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] 24 | ArgMismatch, [INFO] [stdout] 25 | NonIntCalc, [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(dead_code)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: field `entry` is never read [INFO] [stdout] --> src/frontend/context.rs:34:5 [INFO] [stdout] | [INFO] [stdout] 32 | pub struct FunctionInfo { [INFO] [stdout] | ------------ field in this struct [INFO] [stdout] 33 | func: Function, [INFO] [stdout] 34 | entry: BasicBlock, [INFO] [stdout] | ^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: methods `print` and `as_runtime` are never used [INFO] [stdout] --> src/frontend/context.rs:235:8 [INFO] [stdout] | [INFO] [stdout] 234 | impl CTValue { [INFO] [stdout] | ------------ methods in this implementation [INFO] [stdout] 235 | fn print(&self, context: &mut Context, program: &mut Program) { [INFO] [stdout] | ^^^^^ [INFO] [stdout] ... [INFO] [stdout] 244 | fn as_runtime(&self) -> Value { [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: associated function `to_triple` is never used [INFO] [stdout] --> /opt/rustwide/target/debug/build/compiler-learning-d349568f895331bc/out/sysy.rs:6362:8 [INFO] [stdout] | [INFO] [stdout] 6360 | pub trait __ToTriple<'input, > [INFO] [stdout] | ---------- associated function in this trait [INFO] [stdout] 6361 | { [INFO] [stdout] 6362 | fn to_triple(value: Self) -> Result<(usize,Token<'input>,usize), __lalrpop_util::ParseError, &'static str>>; [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: 22 warnings emitted [INFO] [stdout] [INFO] [stdout] [INFO] [stderr] Finished `dev` profile [unoptimized + debuginfo] target(s) in 12.28s [INFO] [stderr] warning: the following packages contain code that will be rejected by a future version of Rust: lalrpop v0.19.8 [INFO] [stderr] note: to see what the problems were, use the option `--future-incompat-report`, or run `cargo report future-incompatibilities --id 1` [INFO] [stderr] Running `cargo check` to verify 2024 [INFO] [stderr] Compiling compiler-learning v0.1.0 (/tmp/fixit) [INFO] [stdout] error: expected identifier, found reserved keyword `gen` [INFO] [stdout] --> src/main.rs:7:21 [INFO] [stdout] | [INFO] [stdout] 7 | use crate::backend::gen::Gen; [INFO] [stdout] | ^^^ expected identifier, found reserved keyword [INFO] [stdout] | [INFO] [stdout] help: escape `gen` to use it as an identifier [INFO] [stdout] | [INFO] [stdout] 7 | use crate::backend::r#gen::Gen; [INFO] [stdout] | ++ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error: expected identifier, found reserved keyword `gen` [INFO] [stdout] --> src/main.rs:7:21 [INFO] [stdout] | [INFO] [stdout] 7 | use crate::backend::gen::Gen; [INFO] [stdout] | ^^^ expected identifier, found reserved keyword [INFO] [stdout] | [INFO] [stdout] help: escape `gen` to use it as an identifier [INFO] [stdout] | [INFO] [stdout] 7 | use crate::backend::r#gen::Gen; [INFO] [stdout] | ++ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error: expected identifier, found reserved keyword `gen` [INFO] [stdout] --> src/main.rs:9:22 [INFO] [stdout] | [INFO] [stdout] 9 | use crate::frontend::gen::compile_koopa; [INFO] [stdout] | ^^^ expected identifier, found reserved keyword [INFO] [stdout] | [INFO] [stdout] help: escape `gen` to use it as an identifier [INFO] [stdout] | [INFO] [stdout] 9 | use crate::frontend::r#gen::compile_koopa; [INFO] [stdout] | ++ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error: expected identifier, found reserved keyword `gen` [INFO] [stdout] --> src/main.rs:9:22 [INFO] [stdout] | [INFO] [stdout] 9 | use crate::frontend::gen::compile_koopa; [INFO] [stdout] | ^^^ expected identifier, found reserved keyword [INFO] [stdout] | [INFO] [stdout] help: escape `gen` to use it as an identifier [INFO] [stdout] | [INFO] [stdout] 9 | use crate::frontend::r#gen::compile_koopa; [INFO] [stdout] | ++ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error: expected identifier, found reserved keyword `gen` [INFO] [stdout] --> src/backend/mod.rs:1:9 [INFO] [stdout] | [INFO] [stdout] 1 | pub mod gen; [INFO] [stdout] | ^^^ expected identifier, found reserved keyword [INFO] [stdout] | [INFO] [stdout] help: escape `gen` to use it as an identifier [INFO] [stdout] | [INFO] [stdout] 1 | pub mod r#gen; [INFO] [stdout] | ++ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error: expected identifier, found reserved keyword `gen` [INFO] [stdout] --> src/backend/mod.rs:1:9 [INFO] [stdout] | [INFO] [stdout] 1 | pub mod gen; [INFO] [stdout] | ^^^ expected identifier, found reserved keyword [INFO] [stdout] | [INFO] [stdout] help: escape `gen` to use it as an identifier [INFO] [stdout] | [INFO] [stdout] 1 | pub mod r#gen; [INFO] [stdout] | ++ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error: expected identifier, found reserved keyword `gen` [INFO] [stdout] --> src/frontend/mod.rs:5:9 [INFO] [stdout] | [INFO] [stdout] 5 | pub mod gen; [INFO] [stdout] | ^^^ expected identifier, found reserved keyword [INFO] [stdout] | [INFO] [stdout] help: escape `gen` to use it as an identifier [INFO] [stdout] | [INFO] [stdout] 5 | pub mod r#gen; [INFO] [stdout] | ++ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error: expected identifier, found reserved keyword `gen` [INFO] [stdout] --> src/frontend/mod.rs:5:9 [INFO] [stdout] | [INFO] [stdout] 5 | pub mod gen; [INFO] [stdout] | ^^^ expected identifier, found reserved keyword [INFO] [stdout] | [INFO] [stdout] help: escape `gen` to use it as an identifier [INFO] [stdout] | [INFO] [stdout] 5 | pub mod r#gen; [INFO] [stdout] | ++ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error: expected identifier, found reserved keyword `gen` [INFO] [stdout] --> src/frontend/gen.rs:15:13 [INFO] [stdout] | [INFO] [stdout] 15 | let mut gen = KoopaGenerator::new(vec![]); [INFO] [stdout] | ^^^ expected identifier, found reserved keyword [INFO] [stdout] | [INFO] [stdout] help: escape `gen` to use it as an identifier [INFO] [stdout] | [INFO] [stdout] 15 | let mut r#gen = KoopaGenerator::new(vec![]); [INFO] [stdout] | ++ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error: expected expression, found reserved keyword `gen` [INFO] [stdout] --> src/frontend/gen.rs:16:5 [INFO] [stdout] | [INFO] [stdout] 16 | gen.generate_on(&program).expect("koopa ir generation failed"); [INFO] [stdout] | ^^^ expected expression [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error: expected identifier, found reserved keyword `gen` [INFO] [stdout] --> src/frontend/gen.rs:15:13 [INFO] [stdout] | [INFO] [stdout] 15 | let mut gen = KoopaGenerator::new(vec![]); [INFO] [stdout] | ^^^ expected identifier, found reserved keyword [INFO] [stdout] | [INFO] [stdout] help: escape `gen` to use it as an identifier [INFO] [stdout] | [INFO] [stdout] 15 | let mut r#gen = KoopaGenerator::new(vec![]); [INFO] [stdout] | ++ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error: expected expression, found reserved keyword `gen` [INFO] [stdout] --> src/frontend/gen.rs:16:5 [INFO] [stdout] | [INFO] [stdout] 16 | gen.generate_on(&program).expect("koopa ir generation failed"); [INFO] [stdout] | ^^^ expected expression [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `std::fmt::write` [INFO] [stdout] --> src/frontend/mod.rs:2:5 [INFO] [stdout] | [INFO] [stdout] 2 | use std::fmt::write; [INFO] [stdout] | ^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_imports)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `FuncFParam` [INFO] [stdout] --> src/frontend/gen.rs:5:126 [INFO] [stdout] | [INFO] [stdout] 5 | ... ConstDef, ConstExp, ConstInitVal, Decl, EqExp, Exp, FuncDef, FuncFParam, FuncFParams, FuncType, GlobalDef, InitVal, LAndExp, LOrExp, ... [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `ValueBuilder` [INFO] [stdout] --> src/frontend/context.rs:3:77 [INFO] [stdout] | [INFO] [stdout] 3 | use koopa::ir::builder::{BasicBlockBuilder, LocalBuilder, LocalInstBuilder, ValueBuilder}; [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `ValueKind` [INFO] [stdout] --> src/frontend/eval.rs:1:26 [INFO] [stdout] | [INFO] [stdout] 1 | use koopa::ir::{Program, ValueKind}; [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `cur_func` [INFO] [stdout] --> src/frontend/eval.rs:3:50 [INFO] [stdout] | [INFO] [stdout] 3 | use crate::frontend::context::{Context, CTValue, cur_func}; [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `std::fmt::write` [INFO] [stdout] --> src/frontend/mod.rs:2:5 [INFO] [stdout] | [INFO] [stdout] 2 | use std::fmt::write; [INFO] [stdout] | ^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_imports)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `FuncFParam` [INFO] [stdout] --> src/frontend/gen.rs:5:126 [INFO] [stdout] | [INFO] [stdout] 5 | ... ConstDef, ConstExp, ConstInitVal, Decl, EqExp, Exp, FuncDef, FuncFParam, FuncFParams, FuncType, GlobalDef, InitVal, LAndExp, LOrExp, ... [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `ValueBuilder` [INFO] [stdout] --> src/frontend/context.rs:3:77 [INFO] [stdout] | [INFO] [stdout] 3 | use koopa::ir::builder::{BasicBlockBuilder, LocalBuilder, LocalInstBuilder, ValueBuilder}; [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `ValueKind` [INFO] [stdout] --> src/frontend/eval.rs:1:26 [INFO] [stdout] | [INFO] [stdout] 1 | use koopa::ir::{Program, ValueKind}; [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `cur_func` [INFO] [stdout] --> src/frontend/eval.rs:3:50 [INFO] [stdout] | [INFO] [stdout] 3 | use crate::frontend::context::{Context, CTValue, cur_func}; [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `codes` [INFO] [stdout] --> src/backend/gen.rs:7:24 [INFO] [stdout] | [INFO] [stdout] 7 | fn generate(&self, codes: &mut Vec) { [INFO] [stdout] | ^^^^^ help: if this is intentional, prefix it with an underscore: `_codes` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_variables)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `codes` [INFO] [stdout] --> src/backend/gen.rs:11:36 [INFO] [stdout] | [INFO] [stdout] 11 | fn visit_with_func_data(&self, codes: &mut Vec, func_data: &FunctionData) { [INFO] [stdout] | ^^^^^ help: if this is intentional, prefix it with an underscore: `_codes` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `func_data` [INFO] [stdout] --> src/backend/gen.rs:11:61 [INFO] [stdout] | [INFO] [stdout] 11 | fn visit_with_func_data(&self, codes: &mut Vec, func_data: &FunctionData) { [INFO] [stdout] | ^^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_func_data` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `codes` [INFO] [stdout] --> src/backend/gen.rs:7:24 [INFO] [stdout] | [INFO] [stdout] 7 | fn generate(&self, codes: &mut Vec) { [INFO] [stdout] | ^^^^^ help: if this is intentional, prefix it with an underscore: `_codes` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_variables)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `codes` [INFO] [stdout] --> src/backend/gen.rs:11:36 [INFO] [stdout] | [INFO] [stdout] 11 | fn visit_with_func_data(&self, codes: &mut Vec, func_data: &FunctionData) { [INFO] [stdout] | ^^^^^ help: if this is intentional, prefix it with an underscore: `_codes` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `func_data` [INFO] [stdout] --> src/backend/gen.rs:11:61 [INFO] [stdout] | [INFO] [stdout] 11 | fn visit_with_func_data(&self, codes: &mut Vec, func_data: &FunctionData) { [INFO] [stdout] | ^^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_func_data` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `is_void` [INFO] [stdout] --> src/frontend/gen.rs:630:33 [INFO] [stdout] | [INFO] [stdout] 630 | let (params_ty, is_void) = { [INFO] [stdout] | ^^^^^^^ help: if this is intentional, prefix it with an underscore: `_is_void` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `is_void` [INFO] [stdout] --> src/frontend/gen.rs:630:33 [INFO] [stdout] | [INFO] [stdout] 630 | let (params_ty, is_void) = { [INFO] [stdout] | ^^^^^^^ help: if this is intentional, prefix it with an underscore: `_is_void` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error: aborting due to 6 previous errors; 9 warnings emitted [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error: aborting due to 6 previous errors; 9 warnings emitted [INFO] [stdout] [INFO] [stdout] [INFO] [stderr] error: could not compile `compiler-learning` (bin "compiler-learning") due to 7 previous errors; 9 warnings emitted [INFO] [stderr] warning: build failed, waiting for other jobs to finish... [INFO] [stderr] error: could not compile `compiler-learning` (bin "compiler-learning" test) due to 7 previous errors; 9 warnings emitted [INFO] [stderr] error: failed to check after updating to 2024 [INFO] [stderr] [INFO] [stderr] Caused by: [INFO] [stderr] process didn't exit successfully: `cargo check --frozen --all --all-targets --message-format=json` (exit status: 101) [INFO] running `Command { std: "docker" "inspect" "d0402468320ae88023b86402ba67793fdda14b3d744f05fd94ccfa491fab3780", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "d0402468320ae88023b86402ba67793fdda14b3d744f05fd94ccfa491fab3780", kill_on_drop: false }` [INFO] [stdout] d0402468320ae88023b86402ba67793fdda14b3d744f05fd94ccfa491fab3780