[Date Prev][Date Next][Thread Prev][Thread Next]
- Subject: Re: Timing out LUA programs
- From: Edgar Toernig <froese@...>
- Date: Wed, 19 Jun 2002 19:07:06 +0200
Benjohn Barnes wrote:
> Is there any difference between coroutines and co-operative threads?
They are basically the same. Add a scheduler to coroutines and you
get co-operative threads.
PS: That's how I explain coroutines: "Think of them as minimalistic
threads without a scheduler. Because there's no scheduler you have
to explicitely say which 'thread' (coroutine) should run next."
Everything else comes automatically from this definition (i.e. can
a coroutine terminate? How to delete one. Can it "return"? ...).