You might be wondering why I didn't take the following approach: Register a custom sink func for GInitiallyUnowned that does ref_sink+unref, and then in gperl_object_new simply enforce own=1 for GInitiallyUnowned descendants. This would indeed be mostly equivalent to the patch, and would conceptually be cleaner. But I worry that their might be some weird class out there that does not descend from GInitiallyUnowned to get floating ref behavior but instead uses gobject's floating refs manually, via g_object_force_floating.
Attachment:
0001-Handle-ownership-of-objects-with-floating-refs-corre.patch
Description: Text Data