Re: [Vala] Questions on async functions
- From: Sam Wilson <tecywiz121 hotmail com>
- To: <vala-list gnome org>
- Subject: Re: [Vala] Questions on async functions
- Date: Wed, 3 Feb 2010 10:01:47 -0500
Q2.
Any hope of getting the following replaced
with a better syntax? :-)
Idle.add(async_function.callback);
yield;
Why not simply:
yield;
?
Because 'yield' just stops the method until the callback resumes it. It
does nothing else. You can for example wait for a signal this way.
Resuming in an idle callback is just one of the possibilities.
Why not
yield Idle;
or even
yield until Idle;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]