GNOME Bugzilla – Bug 648957
GIR Writer: vfuncs don't include instance parameter
Last modified: 2011-05-23 16:52:39 UTC
When defining an abstract method such as: public abstract void some_method (); It is interpreted as a vfunc, which is great, but in the gir output the instance parameter is missing, we get: <field name="some_method"> <callback name="keyboard_some_method" c:type="keyboard_some_method"> <return-value transfer-ownership="none"> <type name="none"/> </return-value> </callback> </field> Where we should get: <field name="some_method"> <callback c:type="keyboard_some_method" name="keyboard_some_method"> <parameters> <parameter name="self" transfer-ownership="none"> <type c:type="CaribouKeyboard" name="Keyboard"/> </parameter> </parameters> <return-value transfer-ownership="none"> <type name="none"/> </return-value> </callback> </field> This makes it hard to override the method properly in pygi since we can't pass the instance variable to the method.
commit ec7f7b1f15f08c49d70200a1b9226be6e0231abf Author: Luca Bruno <lucabru@src.gnome.org> Date: Mon May 23 18:43:49 2011 +0200 girwriter: Add self parameter to the callback of virtual methods field Fixes bug 650607. This problem has been fixed in the development version. The fix will be available in the next major software release. Thank you for your bug report.