rust/src/test/compile-fail/closure-bounds-not-builtin.rs

8 lines
133 B
Rust
Raw Normal View History

trait Foo {}
fn take(f: &fn:Foo()) {
//~^ ERROR only the builtin traits can be used as closure or object bounds
}
fn main() {}