blob: 1211625dac9cc81251e299c080bee58417f7981b (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
|
// Regression test for issue #59342
// Checks that we properly detect defining uses of opaque
// types in 'item' position when generic parameters are involved
//
// run-pass
#![feature(impl_trait_in_assoc_type)]
trait Meow {
type MeowType;
fn meow(self) -> Self::MeowType;
}
impl<T, I> Meow for I
where
I: Iterator<Item = T>,
{
type MeowType = impl Iterator<Item = T>;
fn meow(self) -> Self::MeowType {
self
}
}
fn main() {}
|