error[E0308]: mismatched types --> $DIR/typeck_type_placeholder_mismatch.rs:23:21 | LL | let x: Foo<_> = Bar::(PhantomData); | ^^^^^^^^^^^^^^^^^^^^^^^^^ expected struct `Foo`, found struct `Bar` | = note: expected type `Foo<_>` found type `Bar` error[E0308]: mismatched types --> $DIR/typeck_type_placeholder_mismatch.rs:32:21 | LL | let x: Foo<_> = Bar::(PhantomData); | ^^^^^^^^^^^^^^^^^^^^^^^^^ expected struct `Foo`, found struct `Bar` | = note: expected type `Foo<_>` found type `Bar` error: aborting due to 2 previous errors For more information about this error, try `rustc --explain E0308`.