[Vala] Threads and async (was: Threads and closures problem)

Jörn's mail about threads and closures reminded me about a problem I
wanted to highlight here.

The addition of async functions in Vala is a very great feature, however
I wonder how this could work with multiple threads? As far as I know,
the continuation is scheduled to be an idle callback against the main
context, right? If so, then this would mean that an async functions in a
thread B would only run in the B-context until the first 'yield',
afterwards it would continue to run in the A-context -- obviously
defeating the purpose of multithreading.

Are my worries justified and if so, how could we fix that?



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]