From: Jürg Billeter Date: Sun, 13 Sep 2009 13:15:12 +0000 (+0200) Subject: GType: Remove duplicated code for interface vfunc declarators X-Git-Tag: 0.7.6~114 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=b41c8b8f76740acfb72c20d034000cae7b6f0c54;p=thirdparty%2Fvala.git GType: Remove duplicated code for interface vfunc declarators --- diff --git a/codegen/valagtypemodule.vala b/codegen/valagtypemodule.vala index 6b7f3ec58..df8c99acc 100644 --- a/codegen/valagtypemodule.vala +++ b/codegen/valagtypemodule.vala @@ -1695,19 +1695,7 @@ internal class Vala.GTypeModule : GErrorModule { type_struct.add_field ("GTypeInterface", "parent_iface"); foreach (Method m in iface.get_methods ()) { - if ((!m.is_abstract && !m.is_virtual) || m.coroutine) { - continue; - } - - // add vfunc field to the type struct - var vdeclarator = new CCodeFunctionDeclarator (m.vfunc_name); - var cparam_map = new HashMap (direct_hash, direct_equal); - - generate_cparameters (m, decl_space, cparam_map, new CCodeFunction ("fake"), vdeclarator); - - var vdecl = new CCodeDeclaration (m.return_type.get_cname ()); - vdecl.add_declarator (vdeclarator); - type_struct.add_declaration (vdecl); + generate_virtual_method_declaration (m, decl_space, type_struct); } foreach (Property prop in iface.get_properties ()) {