]> git.lizzy.rs Git - rust.git/blob - src/test/ui/impl-trait/issue-72911.rs
Auto merge of #95604 - nbdd0121:used2, r=petrochenkov
[rust.git] / src / test / ui / impl-trait / issue-72911.rs
1 // Regression test for #72911.
2
3 pub struct Lint {}
4
5 impl Lint {}
6
7 pub fn gather_all() -> impl Iterator<Item = Lint> {
8     //~^ ERROR `()` is not an iterator
9     lint_files().flat_map(|f| gather_from_file(&f))
10 }
11
12 fn gather_from_file(dir_entry: &foo::MissingItem) -> impl Iterator<Item = Lint> {
13     //~^ ERROR: failed to resolve
14     unimplemented!()
15 }
16
17 fn lint_files() -> impl Iterator<Item = foo::MissingItem> {
18     //~^ ERROR: failed to resolve
19     unimplemented!()
20 }
21
22 fn main() {}