rustc/tests/ui/issues/issue-44239.fixed
2024-06-21 09:39:33 +02:00

12 lines
220 B
Plaintext

//@ run-rustfix
#![allow(dead_code, non_upper_case_globals)]
fn main() {
const n: usize = 0;
struct Foo;
impl Foo {
const N: usize = n;
//~^ ERROR attempt to use a non-constant value
}
}