blob: 75dcdc59f21c1a292ac3288ce0258a71cb5181d2 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
|
// build-fail
// compile-flags: -Copt-level=0
// normalize-stderr-test: "long-type-\d+" -> "long-type-hash"
//~^^^ ERROR overflow evaluating the requirement
// ignore-compare-mode-next-solver (hangs)
fn main() {
let mut iter = 0u8..1;
func(&mut iter)
}
fn func<T: Iterator<Item = u8>>(iter: &mut T) { //~ WARN function cannot return without recursing
func(&mut iter.map(|x| x + 1))
}
|