]> git.lizzy.rs Git - rust.git/blob - src/test/ui/numbers-arithmetic/promoted_overflow_opt.rs
Rollup merge of #102016 - lcnr:given-OutlivesEnvironment, r=jackh726
[rust.git] / src / test / ui / numbers-arithmetic / promoted_overflow_opt.rs
1 // run-pass
2 #![allow(const_err)]
3
4 // compile-flags: -O
5
6 fn main() {
7     let x = &(0u32 - 1);
8     assert_eq!(*x, u32::MAX)
9 }