]> git.lizzy.rs Git - rust.git/blob - src/test/ui/issues/issue-22346.rs
Special sync of 'e89801553ddbaccdeb2eac4db08900edb51ac7ff'
[rust.git] / src / test / ui / issues / issue-22346.rs
1 // run-pass
2 #![allow(dead_code)]
3 // pretty-expanded FIXME #23616
4
5 // This used to cause an ICE because the retslot for the "return" had the wrong type
6 fn testcase<'a>() -> Box<dyn Iterator<Item=usize> + 'a> {
7     return Box::new((0..3).map(|i| { return i; }));
8 }
9
10 fn main() {
11 }