From 8e65d97d3da6e0090685150699f7082fa679e25f Mon Sep 17 00:00:00 2001 From: neingeist Date: Mon, 18 Aug 2014 21:59:02 +0200 Subject: [PATCH] a better future --- future.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/future.cpp b/future.cpp index 26384d8..7de407f 100644 --- a/future.cpp +++ b/future.cpp @@ -6,8 +6,8 @@ #include // std::chrono::milliseconds // a non-optimized way of checking for prime numbers. -bool is_prime (int x) { - for (int i=2; i fut = std::async(std::launch::async, is_prime, p2); std::cout << "just getting the result, doing an implicit wait():" << std::endl;