summaryrefslogtreecommitdiffstats
path: root/src/test/ui/consts/const-eval/pub_const_err.rs
blob: 5faacd556d47957e632d0266f1c3228391b142db (plain)
1
2
3
4
5
6
7
8
9
10
// check-pass
#![warn(const_err)]

#![crate_type = "lib"]

pub const Z: u32 = 0 - 1;
//~^ WARN any use of this value will cause an error
//~| WARN this was previously accepted by the compiler but is being phased out

pub type Foo = [i32; 0 - 1];