Skip to content

Commit 655ef94

Browse files
author
Conor
committed
cleanup
1 parent d1066a1 commit 655ef94

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

src/core/promise.cxx

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -162,6 +162,9 @@ struct final_awaitable : std::suspend_always {
162162

163163
// =============== Fork/Call =============== //
164164

165+
/**
166+
* @brief Call inside a catch block, stash current exception in `frame`.
167+
*/
165168
template <worker_context Context>
166169
constexpr void stash_current_exception(frame_type<Context> *frame) noexcept {
167170
// No synchronisation is done via exception_bit, hence we can use relaxed atomics
@@ -182,9 +185,6 @@ constexpr void stash_current_exception(frame_type<Context> *frame) noexcept {
182185
template <category Cat, worker_context Context>
183186
struct awaitable : std::suspend_always {
184187

185-
using enum category;
186-
using except_type = frame_type<Context>::except_type;
187-
188188
frame_type<Context> *child;
189189

190190
/**
@@ -220,7 +220,7 @@ struct awaitable : std::suspend_always {
220220
self.child->stack_ckpt = not_null(thread_context<Context>)->alloc().checkpoint();
221221
self.child->kind = Cat;
222222

223-
if constexpr (Cat == fork) {
223+
if constexpr (Cat == category::fork) {
224224
// It is critical to pass self by-value here, after the call to push()
225225
// the object `*this` may be destroyed, if passing by ref it would be
226226
// use-after-free to then access self in the following line to fetch the

0 commit comments

Comments
 (0)