C
Charles Lowe
Is there anyway around the blocking IO on windows? I'm trying to write
an ruby app that is designed to be used from irb. It uses background
threads to do some work, but they don't appear to block at input on
windows.
Eg, running:
Thread.new { sleep 2; p 'hi' }
on windows, from irb, will never print 'hi', unless you press some keys.
Meanwhile on linux it will print just fine after 2 seconds.
an ruby app that is designed to be used from irb. It uses background
threads to do some work, but they don't appear to block at input on
windows.
Eg, running:
Thread.new { sleep 2; p 'hi' }
on windows, from irb, will never print 'hi', unless you press some keys.
Meanwhile on linux it will print just fine after 2 seconds.