Function Reactor.dontYield

Don't yield

void dontYield () nothrow @nogc @safe;

This function should called by functions that might yield but, in this case, don't. For example, Lock.acquire calls this function if the lock is available and no sleep is necessary.

This function checks certain condition that have to happen in case a yield happens (such as that we're not inside a critical section). Under the "fail early" doctrine, we want those asserts to fail despite the fact we do not, actually, yield in this case.

This function also resets certain flags that are meant to take effect only until the next context switch, such as calls to boostFiberPriority.