mirror of
https://github.com/rust-lang/rust.git
synced 2026-05-31 21:47:15 +03:00
42 lines
1.7 KiB
Plaintext
42 lines
1.7 KiB
Plaintext
error[E0391]: cycle detected when checking if `FOO` is a trivial const
|
|
--> $DIR/recursive-const-stack-overflow.rs:3:1
|
|
|
|
|
LL | const FOO: usize = FOO;
|
|
| ^^^^^^^^^^^^^^^^
|
|
|
|
|
note: ...which requires building MIR for `FOO`...
|
|
--> $DIR/recursive-const-stack-overflow.rs:3:1
|
|
|
|
|
LL | const FOO: usize = FOO;
|
|
| ^^^^^^^^^^^^^^^^
|
|
= note: ...which again requires checking if `FOO` is a trivial const, completing the cycle
|
|
note: cycle used when simplifying constant for the type system `FOO`
|
|
--> $DIR/recursive-const-stack-overflow.rs:3:1
|
|
|
|
|
LL | const FOO: usize = FOO;
|
|
| ^^^^^^^^^^^^^^^^
|
|
= note: see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information
|
|
|
|
error[E0391]: cycle detected when checking if `main::BAR` is a trivial const
|
|
--> $DIR/recursive-const-stack-overflow.rs:8:9
|
|
|
|
|
LL | const BAR: usize = BAR;
|
|
| ^^^^^^^^^^^^^^^^
|
|
|
|
|
note: ...which requires building MIR for `main::BAR`...
|
|
--> $DIR/recursive-const-stack-overflow.rs:8:9
|
|
|
|
|
LL | const BAR: usize = BAR;
|
|
| ^^^^^^^^^^^^^^^^
|
|
= note: ...which again requires checking if `main::BAR` is a trivial const, completing the cycle
|
|
note: cycle used when simplifying constant for the type system `main::BAR`
|
|
--> $DIR/recursive-const-stack-overflow.rs:8:9
|
|
|
|
|
LL | const BAR: usize = BAR;
|
|
| ^^^^^^^^^^^^^^^^
|
|
= note: see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information
|
|
|
|
error: aborting due to 2 previous errors
|
|
|
|
For more information about this error, try `rustc --explain E0391`.
|