summaryrefslogtreecommitdiffstats
path: root/tests/ui/coroutine/auxiliary/xcrate-reachable.rs
blob: 673153f0619ead10ba3bcc919c6b8763d827381d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
#![feature(coroutines, coroutine_trait)]

use std::ops::Coroutine;

fn msg() -> u32 {
    0
}

pub fn foo() -> impl Coroutine<(), Yield = (), Return = u32> {
    || {
        yield;
        return msg();
    }
}