Context 终于进 boost 了
New Libraries: Context
Boost.Context
is a foundational library that provides a sort of cooperative multitasking on a single thread. By providing an abstraction of the current execution state in the current thread, including the stack (with local variables) and stack pointer, all registers and CPU flags, and the instruction pointer, afcontext_t instance represents a specific point in the application’s execution path. This is useful for building higher-level abstractions, like coroutines,cooperative threads (userland threads) or an aquivalent to C# keyword yield in C++.
boost 不是已经有Coroutines了,再有这个不重复吗
Coroutine 当初只是一个提案,审核没通过