1 // error-pattern: copying a noncopyable value
3 fn to_lambda2(b: block(uint) -> uint) -> fn@(uint) -> uint {
4 // test case where copy clause specifies a value that is not used
5 // in fn@ body, but value is illegal to copy:
6 ret fn@[copy b](u: uint) -> uint { 22u };