rust/tests/rustdoc/synthetic_auto/issue-72213-projection-lifetime.rs
2023-01-11 09:32:08 +00:00

26 lines
488 B
Rust

// Regression test for issue #72213
// Tests that we don't ICE when we have projection predicates
// in our initial ParamEnv
pub struct Lines<'a, L>
where
L: Iterator<Item = &'a ()>,
{
words: std::iter::Peekable<Words<'a, L>>,
}
pub struct Words<'a, L> {
_m: std::marker::PhantomData<&'a L>,
}
impl<'a, L> Iterator for Words<'a, L>
where
L: Iterator<Item = &'a ()>,
{
type Item = ();
fn next(&mut self) -> Option<Self::Item> {
unimplemented!()
}
}