]> git.lizzy.rs Git - rust.git/blob - tests/ui/consts/partial_qualif.rs
Rollup merge of #106949 - compiler-errors:is-poly, r=BoxyUwU
[rust.git] / tests / ui / consts / partial_qualif.rs
1 use std::cell::Cell;
2
3 const FOO: &(Cell<usize>, bool) = {
4     let mut a = (Cell::new(0), false);
5     a.1 = true; // sets `qualif(a)` to `qualif(a) | qualif(true)`
6     &{a} //~ ERROR cannot refer to interior mutable
7 };
8
9 fn main() {}