Skip to content

Instantly share code, notes, and snippets.

@hkaiser
Created August 23, 2015 19:37
Show Gist options
  • Save hkaiser/3935f20c0963e522c9f1 to your computer and use it in GitHub Desktop.
Save hkaiser/3935f20c0963e522c9f1 to your computer and use it in GitHub Desktop.
template <class T>
auto futurized(const T& t)
{
auto fut = hpx::async(...);
return fut.then(
[&t](auto){...});
}
int main()
{
int i = ...;
auto fut = futurized(i);
...
fut.get();
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment