diff options
-rw-r--r-- | include/ruby/ractor.h | 45 | ||||
-rw-r--r-- | include/ruby/thread_native.h | 17 |
2 files changed, 62 insertions, 0 deletions
@@ -0,0 +1,45 @@ @@ -31,10 +31,14 @@ typedef union rb_thread_lock_union { CRITICAL_SECTION crit; } rb_nativethread_lock_t; #elif defined(HAVE_PTHREAD_H) #include <pthread.h> typedef pthread_t rb_nativethread_id_t; typedef pthread_mutex_t rb_nativethread_lock_t; #else #error "unsupported thread type" @@ -50,6 +54,19 @@ void rb_nativethread_lock_destroy(rb_nativethread_lock_t *lock); void rb_nativethread_lock_lock(rb_nativethread_lock_t *lock); void rb_nativethread_lock_unlock(rb_nativethread_lock_t *lock); RUBY_SYMBOL_EXPORT_END #endif |