block_on

Function block_on 

Source
pub fn block_on<F, R>(fut: F) -> R
where F: Future<Output = R>,
Expand description

Run tasks until completion of a future

ยงImportant

This function WILL NOT allow yielding to the environment that cooperative feature allows, and it will run the executor until the given future is ready. If yielding is expected, this will block forever.