From e297a260d93b2cdb6e1623e255bd022964e9be1b Mon Sep 17 00:00:00 2001 From: Hayodea Hekol Date: Sat, 25 Oct 2025 14:11:09 -0400 Subject: [PATCH] Contin: Rename Exception propagation macros --- include/asynchronousContinuation.h | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/include/asynchronousContinuation.h b/include/asynchronousContinuation.h index 5e76ab8..8a51c85 100644 --- a/include/asynchronousContinuation.h +++ b/include/asynchronousContinuation.h @@ -49,12 +49,18 @@ public: * This macro should be used by the caller to bubble the exception to the * caller. */ - #define CONT_SET_EXC(continuation, type, exc_obj) \ + #define CALLEE_SETEXC(continuation, type, exc_obj) \ (continuation)->exception = std::make_exception_ptr(exc_obj) - #define CONT_SET_EXC_AND_RET(continuation, type, exc_obj) \ + #define CALLEE_SETEXC_CALLCB(continuation, type, exc_obj) \ do { \ - (continuation)->exception = std::make_exception_ptr(exc_obj); \ + CALLEE_SETEXC(continuation, type, exc_obj); \ + (continuation)->callOriginalCb(); \ + } while(0) + + #define CALLEE_SETEXC_CALLCB_RET(continuation, type, exc_obj) \ + do { \ + CALLEE_SETEXC_CALLCB(continuation, type, exc_obj); \ return; \ } while(0)