rust/tests/ui/impl-trait/in-trait/doesnt-satisfy.rs

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

13 lines
201 B
Rust
Raw Normal View History

2022-08-30 23:46:54 -05:00
#![allow(incomplete_features)]
trait Foo {
fn bar() -> impl std::fmt::Display;
}
impl Foo for () {
fn bar() -> () {}
//~^ ERROR `()` doesn't implement `std::fmt::Display`
}
fn main() {}