From: Jürg Billeter Date: Fri, 19 Dec 2008 21:41:10 +0000 (+0000) Subject: Fix temporary async idle support X-Git-Tag: VALA_0_5_4~61 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=acf65f468ee87a935f24ae148aeb50a772bd028b;p=thirdparty%2Fvala.git Fix temporary async idle support 2008-12-19 Jürg Billeter * gobject/valagasyncmodule.vala: Fix temporary async idle support svn path=/trunk/; revision=2230 --- diff --git a/ChangeLog b/ChangeLog index 01cd28092..b36701186 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ +2008-12-19 Jürg Billeter + + * gobject/valagasyncmodule.vala: + + Fix temporary async idle support + 2008-12-19 Jürg Billeter * gobject/valaccodebasemodule.vala: diff --git a/gobject/valagasyncmodule.vala b/gobject/valagasyncmodule.vala index 38fffdafc..ab1ba3ca4 100644 --- a/gobject/valagasyncmodule.vala +++ b/gobject/valagasyncmodule.vala @@ -201,11 +201,15 @@ public class Vala.GAsyncModule : GSignalModule { public override void visit_yield_statement (YieldStatement stmt) { if (stmt.yield_expression == null) { + // should be replaced by a simple return FALSE; when we have + // void idle () yields; + // working in the .vapi + var cfrag = new CCodeFragment (); stmt.ccodenode = cfrag; var idle_call = new CCodeFunctionCall (new CCodeIdentifier ("g_idle_add")); - idle_call.add_argument (new CCodeCastExpression (new CCodeIdentifier (current_method.get_real_cname ()), "GSourceFunc")); + idle_call.add_argument (new CCodeCastExpression (new CCodeIdentifier (current_method.get_real_cname () + "_co"), "GSourceFunc")); idle_call.add_argument (new CCodeIdentifier ("data")); int state = next_coroutine_state++;