]> git.lizzy.rs Git - rust.git/blob - src/test/ui/borrowck/borrowck-move-by-capture-ok.rs
Rollup merge of #65613 - Mark-Simulacrum:rustdoc-preserve-ws, r=GuillaumeGomez
[rust.git] / src / test / ui / borrowck / borrowck-move-by-capture-ok.rs
1 // run-pass
2 #![feature(box_syntax)]
3
4 pub fn main() {
5     let bar: Box<_> = box 3;
6     let h = || -> isize { *bar };
7     assert_eq!(h(), 3);
8 }