[#61822] Plan Developers Meeting Japan April 2014 — Zachary Scott <e@...>

I would like to request developers meeting around April 17 or 18 in this mo=

14 messages 2014/04/03
[#61825] Re: Plan Developers Meeting Japan April 2014 — Urabe Shyouhei <shyouhei@...> 2014/04/03

It's good if we have a meeting then.

[#61826] Re: Plan Developers Meeting Japan April 2014 — Zachary Scott <e@...> 2014/04/03

Regarding openssl issues, I=E2=80=99ve discussed possible meeting time with=

[#61833] Re: Plan Developers Meeting Japan April 2014 — Martin Bo煬et <martin.bosslet@...> 2014/04/03

Hi,

[ruby-core:62080] Re: [ruby-trunk - Bug #9754] [Open] Ruby refuses to run source with Mutex locks though there is no hazard..

From: Joel VanderWerf <joelvanderwerf@...>
Date: 2014-04-17 18:57:39 UTC
List: ruby-core #62080
On 04/17/2014 03:48 AM, thomas.lynch@reasoningtechnology.com wrote:
> Bug #9754: Ruby refuses to run source with Mutex locks though there is no hazard..

A Mutex is not reentrant.

This deadlocks:

     m = Mutex.new
     m.lock
     m.synchronize {}

So does this:

     m = Mutex.new
     m.synchronize {m.synchronize {}}

But Monitor is reentrant, so the following does not deadlock:

     m = Monitor.new
     m.synchronize {m.synchronize {}}

There is no Monitor#lock, but there is MonitorMixin::ConditionVariable, 
which will do what you want.

(Btw, ruby-talk might be better for these questions than the forum.)

In This Thread

Prev Next