2011-12-20 23:56:21 -06:00
|
|
|
// error-pattern: copying a noncopyable value
|
|
|
|
|
2012-01-23 16:59:00 -06:00
|
|
|
fn to_lambda2(b: fn(uint) -> uint) -> fn@(uint) -> uint {
|
2011-12-20 23:56:21 -06:00
|
|
|
// test case where copy clause specifies a value that is not used
|
2012-01-09 18:12:37 -06:00
|
|
|
// in fn@ body, but value is illegal to copy:
|
|
|
|
ret fn@[copy b](u: uint) -> uint { 22u };
|
2011-12-20 23:56:21 -06:00
|
|
|
}
|
|
|
|
|
|
|
|
fn main() {
|
|
|
|
}
|