Merge branch 'fix-g-value-annotations' into 'main'

GObject: Add nullable annotations

See merge request GNOME/glib!3301
This commit is contained in:
Philip Withnall 2023-02-24 17:37:46 +00:00
commit ed6db32677
3 changed files with 6 additions and 6 deletions

View File

@ -439,7 +439,7 @@ g_boxed_free (GType boxed_type,
*
* Get the contents of a %G_TYPE_BOXED derived #GValue.
*
* Returns: (transfer none): boxed contents of @value
* Returns: (transfer none) (nullable): boxed contents of @value
*/
gpointer
g_value_get_boxed (const GValue *value)
@ -459,7 +459,7 @@ g_value_get_boxed (const GValue *value)
* g_boxed_free(), e.g. like: g_boxed_free (G_VALUE_TYPE (@value),
* return_value);
*
* Returns: boxed contents of @value
* Returns: (transfer full) (nullable): boxed contents of @value
*/
gpointer
g_value_dup_boxed (const GValue *value)

View File

@ -4569,7 +4569,7 @@ g_value_take_object (GValue *value,
*
* Get the contents of a %G_TYPE_OBJECT derived #GValue.
*
* Returns: (type GObject.Object) (transfer none): object contents of @value
* Returns: (type GObject.Object) (transfer none) (nullable): object contents of @value
*/
gpointer
g_value_get_object (const GValue *value)
@ -4587,7 +4587,7 @@ g_value_get_object (const GValue *value)
* its reference count. If the contents of the #GValue are %NULL, then
* %NULL will be returned.
*
* Returns: (type GObject.Object) (transfer full): object content of @value,
* Returns: (type GObject.Object) (transfer full) (nullable): object content of @value,
* should be unreferenced when no longer needed.
*/
gpointer

View File

@ -1133,7 +1133,7 @@ g_value_take_string (GValue *value,
*
* Get the contents of a %G_TYPE_STRING #GValue.
*
* Returns: string content of @value
* Returns: (nullable) (transfer none): string content of @value
*/
const gchar*
g_value_get_string (const GValue *value)
@ -1149,7 +1149,7 @@ g_value_get_string (const GValue *value)
*
* Get a copy the contents of a %G_TYPE_STRING #GValue.
*
* Returns: a newly allocated copy of the string content of @value
* Returns: (nullable) (transfer full): a newly allocated copy of the string content of @value
*/
gchar*
g_value_dup_string (const GValue *value)