about summary refs log tree commit homepage
diff options
context:
space:
mode:
authorEric Wong <e@80x24.org>2017-03-22 01:38:31 +0000
committerEric Wong <e@80x24.org>2017-03-22 01:39:38 +0000
commit9d954528d79f6c868313c167f151838dc93a5ce0 (patch)
treeb6b7a7abe9c9025cc7b05d381b1a06794764cc91
parent58c38861d6cb540e5a4239bc2d88df3865ffe1c8 (diff)
downloadsleepy_penguin-9d954528d79f6c868313c167f151838dc93a5ce0.tar.gz
We don't even support 1.9 in the upcoming release, due to the
use of keyword args.
-rw-r--r--ext/sleepy_penguin/sp_copy.h19
1 files changed, 1 insertions, 18 deletions
diff --git a/ext/sleepy_penguin/sp_copy.h b/ext/sleepy_penguin/sp_copy.h
index 83b9554..008d985 100644
--- a/ext/sleepy_penguin/sp_copy.h
+++ b/ext/sleepy_penguin/sp_copy.h
@@ -18,24 +18,7 @@ typedef VALUE (*my_blocking_fn_t)(void*);
         rb_thread_blocking_region((my_blocking_fn_t)(fn),(a),(ubf),(b))
 
 #else /* Ruby 1.8 */
-/* partial emulation of the 1.9 rb_thread_blocking_region under 1.8 */
-#  include <rubysig.h>
-#  define RUBY_UBF_IO ((rb_unblock_function_t *)-1)
-typedef void rb_unblock_function_t(void *);
-typedef void * rb_blocking_function_t(void *);
-static void * WITHOUT_GVL(rb_blocking_function_t *func, void *data1,
-                        rb_unblock_function_t *ubf, void *data2)
-{
-        void *rv;
-
-        assert(RUBY_UBF_IO == ubf && "RUBY_UBF_IO required for emulation");
-
-        TRAP_BEG;
-        rv = func(data1);
-        TRAP_END;
-
-        return rv;
-}
+#  error Ruby 1.8 not supported
 #endif /* ! HAVE_RB_THREAD_BLOCKING_REGION */
 
 #define IO_RUN(fn,data) WITHOUT_GVL((fn),(data),RUBY_UBF_IO,0)