Skip to content

Instantly share code, notes, and snippets.

@avi007i
Last active May 7, 2018 06:58
#include <iostream>
#include <future>
int main()
{
std::cout << "Launch async = " << static_cast<int>(std::launch::async) << '\n';
std::cout << "Launch deferred = " << static_cast<int>(std::launch::deferred) << '\n';
std::cout << "async OR deferred = " << static_cast<int>(std::launch::async|std::launch::deferred) << '\n';
}
/*
Output
Launch asyc = 1
Launch deferred = 2
async OR deferred = 3
*/
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment