Trade stack closure copyability for type soundness.

This commit is contained in:
Ben Blum 2013-06-21 17:58:21 -04:00
parent 98c169e4e5
commit d4722e5333
3 changed files with 37 additions and 15 deletions

View file

@ -29,6 +29,6 @@ fn main() {
copy2(boxed);
let owned: ~fn() = || {};
copy2(owned); //~ ERROR does not fulfill `Copy`
let borrowed: &fn() = || {};
let borrowed: &fn:Copy() = || {};
copy2(borrowed); //~ ERROR does not fulfill `'static`
}