rust/tests/ui/specialization/defaultimpl/out-of-order.rs
2023-01-11 09:32:08 +00:00

20 lines
309 B
Rust

// run-pass
// Test that you can list the more specific impl before the more general one.
#![feature(specialization)] //~ WARN the feature `specialization` is incomplete
trait Foo {
type Out;
}
impl Foo for bool {
type Out = ();
}
default impl<T> Foo for T {
type Out = bool;
}
fn main() {}