|
|
|
|
|
by pjmlp
3037 days ago
|
|
The code snippet example I wrote was actually .NET with TPL. C++ with PPL on Windows, would be task<T> handle = create_task([] { /* ... */ });
And with standard C++ future<T> handle = std::async(std::launch::async, [] { /* ... */ });
In both cases, with C++20 it will be possible to co_await handle, which you can already play with on clang and VC++. |
|