rust/tests/ui/coherence/coherence-default-trait-impl.rs

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

17 lines
244 B
Rust
Raw Normal View History

#![feature(auto_traits)]
#![feature(negative_impls)]
2015-01-26 18:07:31 -06:00
auto trait MySafeTrait {}
2015-01-26 18:07:31 -06:00
struct Foo;
unsafe impl MySafeTrait for Foo {}
//~^ ERROR E0199
unsafe auto trait MyUnsafeTrait {}
impl MyUnsafeTrait for Foo {}
//~^ ERROR E0200
2015-01-26 18:07:31 -06:00
fn main() {}