Merge branch 'atomic-gpointer-annotations' into 'main'

Mark pointer as (type gpointer)

See merge request GNOME/glib!4599
This commit is contained in:
Philip Withnall 2025-05-20 16:05:15 +00:00
commit fb0f3820a1
3 changed files with 23 additions and 23 deletions

View File

@ -57,7 +57,7 @@
/** /**
* g_atomic_int_get: * g_atomic_int_get:
* @atomic: a pointer to a #gint or #guint * @atomic: (type gconstpointer): a pointer to a #gint or #guint
* *
* Gets the current value of @atomic. * Gets the current value of @atomic.
* *
@ -79,7 +79,7 @@ gint
/** /**
* g_atomic_int_set: * g_atomic_int_set:
* @atomic: a pointer to a #gint or #guint * @atomic: (type gpointer): a pointer to a #gint or #guint
* @newval: a new value to store * @newval: a new value to store
* *
* Sets the value of @atomic to @newval. * Sets the value of @atomic to @newval.
@ -101,7 +101,7 @@ void
/** /**
* g_atomic_int_inc: * g_atomic_int_inc:
* @atomic: a pointer to a #gint or #guint * @atomic: (type gpointer): a pointer to a #gint or #guint
* *
* Increments the value of @atomic by 1. * Increments the value of @atomic by 1.
* *
@ -122,7 +122,7 @@ void
/** /**
* g_atomic_int_dec_and_test: * g_atomic_int_dec_and_test:
* @atomic: a pointer to a #gint or #guint * @atomic: (type gpointer): a pointer to a #gint or #guint
* *
* Decrements the value of @atomic by 1. * Decrements the value of @atomic by 1.
* *
@ -146,7 +146,7 @@ gboolean
/** /**
* g_atomic_int_compare_and_exchange: * g_atomic_int_compare_and_exchange:
* @atomic: a pointer to a #gint or #guint * @atomic: (type gpointer): a pointer to a #gint or #guint
* @oldval: the value to compare with * @oldval: the value to compare with
* @newval: the value to conditionally replace with * @newval: the value to conditionally replace with
* *
@ -177,7 +177,7 @@ gboolean
/** /**
* g_atomic_int_compare_and_exchange_full: * g_atomic_int_compare_and_exchange_full:
* @atomic: a pointer to a #gint or #guint * @atomic: (type gpointer): a pointer to a #gint or #guint
* @oldval: the value to compare with * @oldval: the value to compare with
* @newval: the value to conditionally replace with * @newval: the value to conditionally replace with
* @preval: (out): the contents of @atomic before this operation * @preval: (out): the contents of @atomic before this operation
@ -210,7 +210,7 @@ gboolean
/** /**
* g_atomic_int_exchange: * g_atomic_int_exchange:
* @atomic: a pointer to a #gint or #guint * @atomic: (type gpointer): a pointer to a #gint or #guint
* @newval: the value to replace with * @newval: the value to replace with
* *
* Sets the @atomic to @newval and returns the old value from @atomic. * Sets the @atomic to @newval and returns the old value from @atomic.
@ -235,7 +235,7 @@ gint
/** /**
* g_atomic_int_add: * g_atomic_int_add:
* @atomic: a pointer to a #gint or #guint * @atomic: (type gpointer): a pointer to a #gint or #guint
* @val: the value to add * @val: the value to add
* *
* Atomically adds @val to the value of @atomic. * Atomically adds @val to the value of @atomic.
@ -264,7 +264,7 @@ gint
/** /**
* g_atomic_int_and: * g_atomic_int_and:
* @atomic: a pointer to a #gint or #guint * @atomic: (type gpointer): a pointer to a #gint or #guint
* @val: the value to 'and' * @val: the value to 'and'
* *
* Performs an atomic bitwise 'and' of the value of @atomic and @val, * Performs an atomic bitwise 'and' of the value of @atomic and @val,
@ -291,7 +291,7 @@ guint
/** /**
* g_atomic_int_or: * g_atomic_int_or:
* @atomic: a pointer to a #gint or #guint * @atomic: (type gpointer): a pointer to a #gint or #guint
* @val: the value to 'or' * @val: the value to 'or'
* *
* Performs an atomic bitwise 'or' of the value of @atomic and @val, * Performs an atomic bitwise 'or' of the value of @atomic and @val,
@ -318,7 +318,7 @@ guint
/** /**
* g_atomic_int_xor: * g_atomic_int_xor:
* @atomic: a pointer to a #gint or #guint * @atomic: (type gpointer): a pointer to a #gint or #guint
* @val: the value to 'xor' * @val: the value to 'xor'
* *
* Performs an atomic bitwise 'xor' of the value of @atomic and @val, * Performs an atomic bitwise 'xor' of the value of @atomic and @val,
@ -1149,7 +1149,7 @@ guintptr
/** /**
* g_atomic_int_exchange_and_add: * g_atomic_int_exchange_and_add:
* @atomic: a pointer to a #gint * @atomic: (type gpointer): a pointer to a #gint
* @val: the value to add * @val: the value to add
* *
* This function existed before g_atomic_int_add() returned the prior * This function existed before g_atomic_int_add() returned the prior

View File

@ -56,7 +56,7 @@ static GSList *g_futex_address_list = NULL;
/* < private > /* < private >
* g_futex_wait: * g_futex_wait:
* @address: a pointer to an integer * @address: (type gpointer): a pointer to an integer
* @value: the value that should be at @address * @value: the value that should be at @address
* *
* Atomically checks that the value stored at @address is equal to * Atomically checks that the value stored at @address is equal to
@ -80,7 +80,7 @@ g_futex_wait (const gint *address,
/* < private > /* < private >
* g_futex_wake: * g_futex_wake:
* @address: a pointer to an integer * @address: (type gpointer): a pointer to an integer
* *
* Nominally, wakes one thread that is blocked in g_futex_wait() on * Nominally, wakes one thread that is blocked in g_futex_wait() on
* @address (if any thread is currently waiting). * @address (if any thread is currently waiting).
@ -220,7 +220,7 @@ bit_lock_futex_maybe_wake (gconstpointer address, gboolean is_pointer_pointer)
/** /**
* g_bit_lock_and_get: * g_bit_lock_and_get:
* @address: a pointer to an integer * @address: (type gpointer): a pointer to an integer
* @lock_bit: a bit value between 0 and 31 * @lock_bit: a bit value between 0 and 31
* @out_val: (out) (optional): return location for the new value of the integer * @out_val: (out) (optional): return location for the new value of the integer
* *
@ -283,7 +283,7 @@ retry:
/** /**
* g_bit_lock: * g_bit_lock:
* @address: a pointer to an integer * @address: (type gpointer): a pointer to an integer
* @lock_bit: a bit value between 0 and 31 * @lock_bit: a bit value between 0 and 31
* *
* Sets the indicated @lock_bit in @address. If the bit is already * Sets the indicated @lock_bit in @address. If the bit is already
@ -312,7 +312,7 @@ g_bit_lock (volatile gint *address,
/** /**
* g_bit_trylock: * g_bit_trylock:
* @address: a pointer to an integer * @address: (type gpointer) a pointer to an integer
* @lock_bit: a bit value between 0 and 31 * @lock_bit: a bit value between 0 and 31
* *
* Sets the indicated @lock_bit in @address, returning %TRUE if * Sets the indicated @lock_bit in @address, returning %TRUE if
@ -361,7 +361,7 @@ g_bit_trylock (volatile gint *address,
/** /**
* g_bit_unlock: * g_bit_unlock:
* @address: a pointer to an integer * @address: (type gpointer): a pointer to an integer
* @lock_bit: a bit value between 0 and 31 * @lock_bit: a bit value between 0 and 31
* *
* Clears the indicated @lock_bit in @address. If another thread is * Clears the indicated @lock_bit in @address. If another thread is
@ -400,7 +400,7 @@ g_bit_unlock (volatile gint *address,
/** /**
* g_bit_unlock_and_set: * g_bit_unlock_and_set:
* @address: a pointer to an integer * @address: (type gpointer): a pointer to an integer
* @lock_bit: a bit value between 0 and 31 * @lock_bit: a bit value between 0 and 31
* @val: the new value to set * @val: the new value to set
* @preserve_mask: mask for bits from @address to preserve * @preserve_mask: mask for bits from @address to preserve

View File

@ -61,7 +61,7 @@
/** /**
* g_ref_count_init: * g_ref_count_init:
* @rc: the address of a reference count variable * @rc: (out): the address of a reference count variable
* *
* Initializes a reference count variable to 1. * Initializes a reference count variable to 1.
* *
@ -86,7 +86,7 @@ void
/** /**
* g_ref_count_inc: * g_ref_count_inc:
* @rc: the address of a reference count variable * @rc: (inout): the address of a reference count variable
* *
* Increases the reference count. * Increases the reference count.
* *
@ -117,7 +117,7 @@ void
/** /**
* g_ref_count_dec: * g_ref_count_dec:
* @rc: the address of a reference count variable * @rc: (inout): the address of a reference count variable
* *
* Decreases the reference count. * Decreases the reference count.
* *
@ -180,7 +180,7 @@ gboolean
/** /**
* g_atomic_ref_count_init: * g_atomic_ref_count_init:
* @arc: the address of an atomic reference count variable * @arc: (out): the address of an atomic reference count variable
* *
* Initializes a reference count variable to 1. * Initializes a reference count variable to 1.
* *