Hi,

As you can read in comment, this API is difficult to use.  There are
some assumptions for caller.  I'm not sure that these assumptions are
reasonable or not.  This is why we don't put into public API.

BTW, the naming "_with_gvl" is reasonable for native English speakers?


(2011/01/27 15:51), Eric Wong wrote:
> Feature #4328: export rb_thread_call_with_gvl()
> http://redmine.ruby-lang.org/issues/show/4328
> 
> Author: Eric Wong
> Status: Open, Priority: Normal
> Category: core, Target version: 1.9.3
> 
> I think it is general enough to remain supported along
> with the rest of the MRI C API, especially since
> rb_thread_blocking_region() exists and is supported.
> 
> It's useful for interacting with certain C libraries that expect a
> user-supplied callback function so the extension can allocate a Ruby
> object inside the callback.
> 
> It can also be easily made a no-op for Ruby implementations without a
> GVL.
> 
> 
> ----------------------------------------
> http://redmine.ruby-lang.org


-- 
// SASADA Koichi at atdot dot net