2018-08-31 02:04:23 -05:00
|
|
|
// rustfmt-edition: 2018
|
2018-07-29 10:45:31 -05:00
|
|
|
|
|
|
|
fn main() {
|
|
|
|
let x = async { Ok(()) };
|
|
|
|
}
|
2018-07-29 19:20:11 -05:00
|
|
|
|
|
|
|
fn baz() {
|
|
|
|
// test
|
|
|
|
let x = async {
|
|
|
|
// async blocks are great
|
|
|
|
Ok(())
|
|
|
|
};
|
|
|
|
|
|
|
|
let y = async { Ok(()) }; // comment
|
2019-03-20 12:18:02 -05:00
|
|
|
|
|
|
|
spawn(a, async move {
|
|
|
|
action();
|
|
|
|
Ok(())
|
|
|
|
});
|
|
|
|
|
|
|
|
spawn(a, async move || {
|
|
|
|
action();
|
|
|
|
Ok(())
|
|
|
|
});
|
2021-12-23 16:23:51 -06:00
|
|
|
|
|
|
|
spawn(a, static async || {
|
|
|
|
action();
|
|
|
|
Ok(())
|
|
|
|
});
|
|
|
|
|
|
|
|
spawn(a, static async move || {
|
|
|
|
action();
|
|
|
|
Ok(())
|
|
|
|
});
|
2018-07-29 19:20:11 -05:00
|
|
|
}
|