error[E0658]: `while` is not allowed in a `const` --> $DIR/issue-52475.rs:5:9 | LL | / while n < 5 { LL | | LL | | n = (n + 1) % 5; LL | | x = &0; // Materialize a new AllocId LL | | } | |_________^ | = note: see issue #52000 for more information = help: add `#![feature(const_loop)]` to the crate attributes to enable = help: add `#![feature(const_if_match)]` to the crate attributes to enable error[E0080]: evaluation of constant value failed --> $DIR/issue-52475.rs:7:17 | LL | n = (n + 1) % 5; | ^^^^^^^^^^^ exceeded interpreter step limit (see `#[const_eval_limit]`) error: aborting due to 2 previous errors Some errors have detailed explanations: E0080, E0658. For more information about an error, try `rustc --explain E0080`.