GObject: Throw on data stashing methods and refcounting methods
Data stashing methods such as get_data()
, set_data()
don't work in GJS and never have, because they use raw pointers. Moreover, there's a much easier alternative to store arbitrary data on a GObject; just add an expando property.
While we're at it, may as well throw on refcounting methods too such as ref()
and unref()
. We've talked about it for a long time, so maybe we can land this early in the GNOME 47 cycle and revert it if it causes problems.
Inspired by PyGObject: https://gitlab.gnome.org/GNOME/pygobject/-/blob/e51fdc963e42a603e73036a24b2b94b7b403f778/gi/overrides/GObject.py#L501-513 https://gitlab.gnome.org/GNOME/pygobject/-/blob/e51fdc963e42a603e73036a24b2b94b7b403f778/gi/overrides/GObject.py#L531-534
Closes: #423 (closed)