2023-12-19 05:17:10 -06:00
|
|
|
LL| |#![feature(coverage_attribute)]
|
|
|
|
LL| |#![feature(noop_waker)]
|
|
|
|
LL| |//@ edition: 2021
|
|
|
|
LL| |
|
2024-09-06 00:41:10 -05:00
|
|
|
LL| |//@ aux-build: executor.rs
|
|
|
|
LL| |extern crate executor;
|
|
|
|
LL| |
|
2023-12-19 05:17:10 -06:00
|
|
|
LL| 1|fn main() {
|
|
|
|
LL| 17| for i in 0..16 {
|
|
|
|
^16
|
|
|
|
LL| 16| let future = async {
|
|
|
|
LL| 16| if i >= 12 {
|
|
|
|
LL| 4| println!("big");
|
|
|
|
LL| 12| } else {
|
|
|
|
LL| 12| println!("small");
|
|
|
|
LL| 12| }
|
|
|
|
LL| 16| };
|
|
|
|
LL| 16| executor::block_on(future);
|
|
|
|
LL| 16| }
|
|
|
|
LL| 1|}
|
|
|
|
|