]> git.lizzy.rs Git - rust.git/blob - src/test/ui/issues/issue-37051.rs
Move `{core,std}::stream::Stream` to `{core,std}::async_iter::AsyncIterator`.
[rust.git] / src / test / ui / issues / issue-37051.rs
1 // check-pass
2 // ignore-compare-mode-chalk
3
4 #![feature(associated_type_defaults)]
5
6 trait State: Sized {
7     type NextState: State = StateMachineEnded;
8     fn execute(self) -> Option<Self::NextState>;
9 }
10
11 struct StateMachineEnded;
12
13 impl State for StateMachineEnded {
14     fn execute(self) -> Option<Self::NextState> {
15         None
16     }
17 }
18
19 fn main() {}