summaryrefslogtreecommitdiffstats
path: root/tests/ui/closures/issue-111932.rs
blob: eb3fe08cbc409fe10ada6e7af771403c04e0b9c6 (plain)
1
2
3
4
5
6
7
8
9
trait Foo: std::fmt::Debug {}

fn print_foos(foos: impl Iterator<Item = dyn Foo>) {
    foos.for_each(|foo| { //~ ERROR [E0277]
        println!("{:?}", foo); //~ ERROR [E0277]
    });
}

fn main() {}