// check-pass // revisions: full min #![cfg_attr(full, feature(const_generics))] #![cfg_attr(full, allow(incomplete_features))] struct Foo { state: Option<[u8; D]>, } impl Iterator for Foo<{D}> { type Item = [u8; D]; fn next(&mut self) -> Option { if true { return Some(self.state.unwrap().clone()); } else { return Some(self.state.unwrap().clone()); } } } fn main() {}