error[E0277]: the trait bound `(): Foo` is not satisfied --> $DIR/nested-tait-inference.rs:12:13 | LL | fn foo() -> impl Foo { | ^^^^^^^^^^^^^^ the trait `Foo` is not implemented for `()` ... LL | () | -- return type was inferred to be `()` here | = help: the trait `Foo<()>` is implemented for `()` error: aborting due to previous error For more information about this error, try `rustc --explain E0277`.