]> git.lizzy.rs Git - rust.git/blob - src/test/ui/issues/issue-6458.rs
Merge commit '0969bc6dde001e01e7e1f58c8ccd7750f8a49ae1' into sync_cg_clif-2021-03-29
[rust.git] / src / test / ui / issues / issue-6458.rs
1 use std::marker;
2
3 pub struct TypeWithState<State>(marker::PhantomData<State>);
4 pub struct MyState;
5
6 pub fn foo<State>(_: TypeWithState<State>) {}
7
8 pub fn bar() {
9    foo(TypeWithState(marker::PhantomData));
10    //~^ ERROR type annotations needed [E0282]
11 }
12
13 fn main() {
14 }