GNOME Bugzilla – Bug 730193
gdbus-codegen should say that GVariant arguments are consummed if floating
Last modified: 2018-05-24 16:32:16 UTC
It wasn't that clear to be me if floating GVariant were consumed or not when being passed to generated D-Bus call functions. Actually they are but it would be good to have this information in the generated gtk-doc.
I considered this back when I wrote this (years ago) but I think Ryan convinced me to not do it since the Right Thing(tm) to do for public API accepting GVariant is to indeed consume them. That said, I don't object to be more specific so, as they say, patches welcome!
I only think GVariants should be consumed on public APIs that accept GVariants in a building/sending/consuming sort of way... for example, an API that checks if a GVariant is equal to another GVariant would not be expected to consume it. I consider the above statement to be vague enough that it may be worth creating an annotation to document the difference. Perhaps we could sprinkle these around GtkWidget API as well...
-- GitLab Migration Automatic Message -- This bug has been migrated to GNOME's GitLab instance and has been closed from further activity. You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.gnome.org/GNOME/glib/issues/876.