Function tokio::runtime::coop::budget

source ยท
pub(crate) fn budget<R>(f: impl FnOnce() -> R) -> R
Expand description

Runs the given closure with a cooperative task budget. When the function returns, the budget is reset to the value prior to calling the function.