rust/tests/ui/specialization/issue-68830-spurious-diagnostics.rs
2023-01-11 09:32:08 +00:00

24 lines
429 B
Rust

// A regression test for #68830. This checks we don't emit
// a verbose `conflicting implementations` error.
#![feature(specialization)]
#![allow(incomplete_features)]
struct BadStruct {
err: MissingType //~ ERROR: cannot find type `MissingType` in this scope
}
trait MyTrait<T> {
fn foo();
}
impl<T, D> MyTrait<T> for D {
default fn foo() {}
}
impl<T> MyTrait<T> for BadStruct {
fn foo() {}
}
fn main() {}