Merge branch 'wip/clarify-ref-count-api' into 'master'

refcount: Clarify when the ref count ends up undefined

See merge request GNOME/glib!2041
This commit is contained in:
Philip Withnall 2021-04-13 13:41:19 +00:00
commit 23277fbcad

View File

@ -142,6 +142,10 @@ void
*
* Decreases the reference count.
*
* If %TRUE is returned, the reference count reached 0. After this point, @rc
* is an undefined state and must be reinitialized with
* g_ref_count_init() to be used again.
*
* Returns: %TRUE if the reference count reached 0, and %FALSE otherwise
*
* Since: 2.58
@ -249,6 +253,10 @@ void
*
* Atomically decreases the reference count.
*
* If %TRUE is returned, the reference count reached 0. After this point, @arc
* is an undefined state and must be reinitialized with
* g_atomic_ref_count_init() to be used again.
*
* Returns: %TRUE if the reference count reached 0, and %FALSE otherwise
*
* Since: 2.58