boxed: Mark pointer as unowned when discarding boxed object
Sometimes, in the constructor of a boxed object, we will delegate to another constructor, such as GLib.Error() or GLib.Variant.new_internal() and replace the object under construction by the object returned by the delegated constructor. When that happens, the internal GBoxed pointer of the BoxedInstance remains null. That causes problems when eventually the discarded boxed object is garbage collected, and we try to free the pointer. In those cases, mark it as unowned so it is not freed.
Showing with 14 additions and 2 deletions