]> git.lizzy.rs Git - rust.git/blob - tests/ui/borrowck/suggest-storing-local-var-for-vector.rs
Auto merge of #106458 - albertlarsan68:move-tests, r=jyn514
[rust.git] / tests / ui / borrowck / suggest-storing-local-var-for-vector.rs
1 fn main() {
2     let mut vec = vec![0u32; 420];
3     vec[vec.len() - 1] = 123; //~ ERROR cannot borrow `vec` as immutable because it is also borrowed as mutable
4 }