From 6f250c62c7354085332b18551f0ae4dbd6dc5a92 Mon Sep 17 00:00:00 2001 From: Jacob Wujciak-Jens Date: Tue, 14 Jan 2025 19:28:24 +0100 Subject: [PATCH 1/2] remove macro --- r/src/safe-call-into-r-impl.cpp | 4 ---- 1 file changed, 4 deletions(-) diff --git a/r/src/safe-call-into-r-impl.cpp b/r/src/safe-call-into-r-impl.cpp index 92dce7e0ba0a7..a459bfe73d4f1 100644 --- a/r/src/safe-call-into-r-impl.cpp +++ b/r/src/safe-call-into-r-impl.cpp @@ -46,11 +46,7 @@ bool SetEnableSignalStopSource(bool enabled) { // [[arrow::export]] bool CanRunWithCapturedR() { -#if defined(HAS_UNWIND_PROTECT) return MainRThread::GetInstance().Executor() == nullptr; -#else - return false; -#endif } // [[arrow::export]] From 7861bab0fa5cf8903601dd92758e2539ae1ed6f1 Mon Sep 17 00:00:00 2001 From: Jacob Wujciak-Jens Date: Wed, 15 Jan 2025 00:08:46 +0100 Subject: [PATCH 2/2] update header comment --- r/src/safe-call-into-r.h | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/r/src/safe-call-into-r.h b/r/src/safe-call-into-r.h index 0ffd1d16dca01..c00d13b2fbff9 100644 --- a/r/src/safe-call-into-r.h +++ b/r/src/safe-call-into-r.h @@ -29,12 +29,8 @@ #include #include -// Unwind protection was added in R 3.5 and some calls here use it -// and crash R in older versions (ARROW-16201). Implementation provided -// in safe-call-into-r-impl.cpp so that we can skip some tests -// when this feature is not provided. This also checks that there -// is not already an event loop registered (via MainRThread::Executor()), -// because only one of these can exist at any given time. +// This checks that there is not already an event loop registered (via +// MainRThread::Executor()), because only one of these can exist at any given time. bool CanRunWithCapturedR(); // The MainRThread class keeps track of the thread on which it is safe