Commit 3d01efd7 authored by Xavier Thompson's avatar Xavier Thompson

Adapt exceptions.cpp and forkjoin_fibo.cpp

parent dd0c0583
......@@ -25,7 +25,7 @@ Join<void> fail_join() {
}
Join<void> join(int max) {
std::vector<Future<int>> v;
std::vector<Async<int>> v;
for (int i = 0; i < max; i++) {
v.push_back(co_await fork(fib()));
}
......
......@@ -8,8 +8,8 @@ Join<int> fibo(int n) {
if (n < 2) {
co_return n;
}
Future a = co_await fork(fibo(n - 1));
Future b = co_await fork(fibo(n - 2));
Async a = co_await fork(fibo(n - 1));
Async b = co_await fork(fibo(n - 2));
co_await Sync();
co_return a.get() + b.get();
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment