ruby threads? the point?

E

Eric Armstrong

Matt said:
This has been brought up at previous Ruby Conferences. It is my
understanding that it is being worked on. So, relax and watch the
blinking lights.
Yay! Thanks for the news.
I don't get to enough conferences...
:_)
 
E

Eric Armstrong

Jan said:
kbhit returns whether there are any keystrokes in the buffer
getc returns them.
Nice! Didn't know about that kbhit.
That has promise. I wonder if there is a
multi-platform version of that API?

With that capability, I can dispense with
threads altogether, sleep for 1 second
intervals, and look for keyboard input
every time I wake up.

A brain-dead implementation is good enough
for this particular beast...
:_)
 
E

Eric Armstrong

Francis said:
What happens if you just use select to read the file descriptor associated
with stdin? On Windows iirc, this descriptor is already raw. For Solaris
etc
you can just make it raw with termio calls.
Sounds promising. Do you have a bit of code
to go with the suggestion, perchance?
(I'm having a bit of trouble filling in the blanks.)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
474,209
Messages
2,571,088
Members
47,686
Latest member
scamivo

Latest Threads

Top