handle gen/kill sets together

This commit is contained in:
Ariel Ben-Yehuda 2017-12-04 01:00:46 +02:00
parent 243c5a5faa
commit 210f76816f
3 changed files with 51 additions and 51 deletions

View file

@ -8,6 +8,9 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
// revisions: ast mir
//[mir]compile-flags: -Z borrowck=mir
#![feature(box_syntax)]
fn call_f<F:FnOnce() -> isize>(f: F) -> isize {
@ -18,5 +21,6 @@ fn main() {
let t: Box<_> = box 3;
call_f(move|| { *t + 1 });
call_f(move|| { *t + 1 }); //~ ERROR capture of moved value
call_f(move|| { *t + 1 }); //[ast]~ ERROR capture of moved value
//[mir]~^ ERROR use of moved value
}