about summary refs log tree commit diff
path: root/tests/ui/coroutine/drop-tracking-yielding-in-match-guards.rs
blob: 43e42fa85f7f4d107bdefd98cdcabc241c742e44 (plain)
1
2
3
4
5
6
7
8
9
10
11
//@ build-pass
//@ edition:2018

#![feature(coroutines, stmt_expr_attributes)]

fn main() {
    let _ = #[coroutine] static |x: u8| match x {
        y if { yield } == y + 1 => (),
        _ => (),
    };
}