Hi Henrik,

> "In fact, it has. 'wait' always first checks for pending events before
> it goes to sleep."
> Why does it do that?

This is exactly the purpose of 'wait': Wait for events. The milliseconds
are just a timeout value.

> If I had access to a wait that simply stops
> execution and nothing else everything would be good, I tried to create
> one of my own but it uses too much CPU in the loop.

Well, that's easy:

   (call 'sleep 2)

Also (at least on Linux) this works:

   (call 'sleep "0.1")

> "If there are data available on that socket already, that task will be
> executed."
> It is listening (subscribing) for data so there is no data available
> to begin with.

But there must be something, otherwise it would not wake up. Try to
(trace '...) or '$ strace ...' it.

♪♫ Alex
UNSUBSCRIBE: mailto:picolisp@software-lab.de?subject=Unsubscribe

Reply via email to