diff --git a/src/runtime/interrupt.cpp b/src/runtime/interrupt.cpp index b66fd0c8d8..903f665a11 100644 --- a/src/runtime/interrupt.cpp +++ b/src/runtime/interrupt.cpp @@ -42,7 +42,7 @@ void check_heartbeat() { LEAN_THREAD_VALUE(lean_object *, g_cancel_tk, nullptr); -scope_cancel_tk::scope_cancel_tk(lean_object * o):flet(g_cancel_tk, o) {} +LEAN_EXPORT scope_cancel_tk::scope_cancel_tk(lean_object * o):flet(g_cancel_tk, o) {} /* CancelToken.isSet : @& IO.CancelToken → BaseIO Bool */ extern "C" lean_obj_res lean_io_cancel_token_is_set(b_lean_obj_arg cancel_tk, lean_obj_arg); diff --git a/src/runtime/interrupt.h b/src/runtime/interrupt.h index 055363d057..14cf99385b 100644 --- a/src/runtime/interrupt.h +++ b/src/runtime/interrupt.h @@ -43,9 +43,9 @@ public: LEAN_EXPORT void check_heartbeat(); /* Update the thread local `IO.CancelToken` (`nullptr` if unset) */ -class scope_cancel_tk : flet { +class LEAN_EXPORT scope_cancel_tk : flet { public: - scope_cancel_tk(lean_object *); + LEAN_EXPORT scope_cancel_tk(lean_object *); }; /**