mirror of
https://github.com/rust-lang/rust
synced 2024-11-05 20:45:15 +00:00
19 lines
309 B
Rust
19 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 = ();
|
|
}
|
|
|
|
impl<T> Foo for T {
|
|
default type Out = bool;
|
|
}
|
|
|
|
fn main() {}
|