Skip to content

Commit

Permalink
karm-async: Require a implementation for building.
Browse files Browse the repository at this point in the history
  • Loading branch information
sleepy-monax committed Aug 22, 2023
1 parent 15496e9 commit 1e5da4d
Show file tree
Hide file tree
Showing 4 changed files with 19 additions and 3 deletions.
3 changes: 2 additions & 1 deletion src/impls/impl-posix/manifest.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
"provides": [
"karm-base-impl",
"karm-logger-impl",
"karm-sys-impl"
"karm-sys-impl",
"karm-async-impl"
]
}
5 changes: 3 additions & 2 deletions src/libs/karm-async/manifest.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
"type": "lib",
"description": "Coroutine-based asynchronous programming library",
"requires": [
"karm-base"
"karm-base",
"karm-async-impl"
]
}
}
5 changes: 5 additions & 0 deletions src/libs/stdcpp-shim/coroutine
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
#pragma once

#include <cstddef>

namespace std {

template <typename ReturnType, typename... Args>
Expand All @@ -23,6 +25,9 @@ struct coroutine_handle<void> {
coroutine_handle()
: _frame{nullptr} {}

coroutine_handle(std::nullptr_t)
: _frame{nullptr} {}

explicit operator bool() {
return _frame;
}
Expand Down
9 changes: 9 additions & 0 deletions src/libs/stdcpp-shim/cstddef
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
#pragma once

#include <stddef.h>

namespace std {

using nullptr_t = decltype(nullptr);

} // namespace std

0 comments on commit 1e5da4d

Please sign in to comment.