summaryrefslogtreecommitdiffstats
path: root/src/test/ui/lazy-type-alias-impl-trait/unsized_sized_opaque.rs
blob: 007101498238d7f12fc52fabec521565a7b97056 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
// check-pass

fn main() {}

pub struct PairSlices<'a, 'b, T> {
    pub(crate) a0: &'a mut [T],
    pub(crate) a1: &'a mut [T],
    pub(crate) b0: &'b [T],
    pub(crate) b1: &'b [T],
}

impl<'a, 'b, T> PairSlices<'a, 'b, T> {
    pub fn remainder(self) -> impl Iterator<Item = &'b [T]> {
        IntoIterator::into_iter([self.b0, self.b1])
    }
}