function: respect ownership transfer of instance parameters

When calling a method that is (transfer full) on the instance
parameter we need to make an extra ref/copy.

https://bugzilla.gnome.org/show_bug.cgi?id=729545