mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2025-01-12 15:36:17 +01:00
Add (allow-none) annotation for GValue setters.
Assorted g_value_set_xxx() and g_value_take_xxx() functions actually allow NULL in source parameter.
This commit is contained in:
parent
e3219c8425
commit
d4c5e3b156
@ -463,7 +463,7 @@ value_set_boxed_internal (GValue *value,
|
||||
/**
|
||||
* g_value_set_boxed:
|
||||
* @value: a valid #GValue of %G_TYPE_BOXED derived type
|
||||
* @v_boxed: boxed value to be set
|
||||
* @v_boxed: (allow-none): boxed value to be set
|
||||
*
|
||||
* Set the contents of a %G_TYPE_BOXED derived #GValue to @v_boxed.
|
||||
*/
|
||||
@ -480,7 +480,7 @@ g_value_set_boxed (GValue *value,
|
||||
/**
|
||||
* g_value_set_static_boxed:
|
||||
* @value: a valid #GValue of %G_TYPE_BOXED derived type
|
||||
* @v_boxed: static boxed value to be set
|
||||
* @v_boxed: (allow-none): static boxed value to be set
|
||||
*
|
||||
* Set the contents of a %G_TYPE_BOXED derived #GValue to @v_boxed.
|
||||
* The boxed value is assumed to be static, and is thus not duplicated
|
||||
@ -499,7 +499,7 @@ g_value_set_static_boxed (GValue *value,
|
||||
/**
|
||||
* g_value_set_boxed_take_ownership:
|
||||
* @value: a valid #GValue of %G_TYPE_BOXED derived type
|
||||
* @v_boxed: duplicated unowned boxed value to be set
|
||||
* @v_boxed: (allow-none): duplicated unowned boxed value to be set
|
||||
*
|
||||
* This is an internal function introduced mainly for C marshallers.
|
||||
*
|
||||
@ -515,7 +515,7 @@ g_value_set_boxed_take_ownership (GValue *value,
|
||||
/**
|
||||
* g_value_take_boxed:
|
||||
* @value: a valid #GValue of %G_TYPE_BOXED derived type
|
||||
* @v_boxed: duplicated unowned boxed value to be set
|
||||
* @v_boxed: (allow-none): duplicated unowned boxed value to be set
|
||||
*
|
||||
* Sets the contents of a %G_TYPE_BOXED derived #GValue to @v_boxed
|
||||
* and takes over the ownership of the callers reference to @v_boxed;
|
||||
|
@ -3110,7 +3110,7 @@ g_value_object_lcopy_value (const GValue *value,
|
||||
/**
|
||||
* g_value_set_object:
|
||||
* @value: a valid #GValue of %G_TYPE_OBJECT derived type
|
||||
* @v_object: (type GObject.Object): object value to be set
|
||||
* @v_object: (type GObject.Object) (allow-none): object value to be set
|
||||
*
|
||||
* Set the contents of a %G_TYPE_OBJECT derived #GValue to @v_object.
|
||||
*
|
||||
@ -3152,7 +3152,7 @@ g_value_set_object (GValue *value,
|
||||
/**
|
||||
* g_value_set_object_take_ownership: (skip)
|
||||
* @value: a valid #GValue of %G_TYPE_OBJECT derived type
|
||||
* @v_object: object value to be set
|
||||
* @v_object: (allow-none): object value to be set
|
||||
*
|
||||
* This is an internal function introduced mainly for C marshallers.
|
||||
*
|
||||
@ -3168,7 +3168,7 @@ g_value_set_object_take_ownership (GValue *value,
|
||||
/**
|
||||
* g_value_take_object: (skip)
|
||||
* @value: a valid #GValue of %G_TYPE_OBJECT derived type
|
||||
* @v_object: object value to be set
|
||||
* @v_object: (allow-none): object value to be set
|
||||
*
|
||||
* Sets the contents of a %G_TYPE_OBJECT derived #GValue to @v_object
|
||||
* and takes over the ownership of the callers reference to @v_object;
|
||||
|
@ -1417,7 +1417,7 @@ g_param_type_register_static (const gchar *name,
|
||||
/**
|
||||
* g_value_set_param:
|
||||
* @value: a valid #GValue of type %G_TYPE_PARAM
|
||||
* @param: the #GParamSpec to be set
|
||||
* @param: (allow-none): the #GParamSpec to be set
|
||||
*
|
||||
* Set the contents of a %G_TYPE_PARAM #GValue to @param.
|
||||
*/
|
||||
@ -1439,7 +1439,7 @@ g_value_set_param (GValue *value,
|
||||
/**
|
||||
* g_value_set_param_take_ownership: (skip)
|
||||
* @value: a valid #GValue of type %G_TYPE_PARAM
|
||||
* @param: the #GParamSpec to be set
|
||||
* @param: (allow-none): the #GParamSpec to be set
|
||||
*
|
||||
* This is an internal function introduced mainly for C marshallers.
|
||||
*
|
||||
@ -1455,7 +1455,7 @@ g_value_set_param_take_ownership (GValue *value,
|
||||
/**
|
||||
* g_value_take_param: (skip)
|
||||
* @value: a valid #GValue of type %G_TYPE_PARAM
|
||||
* @param: the #GParamSpec to be set
|
||||
* @param: (allow-none): the #GParamSpec to be set
|
||||
*
|
||||
* Sets the contents of a %G_TYPE_PARAM #GValue to @param and takes
|
||||
* over the ownership of the callers reference to @param; the caller
|
||||
|
@ -326,7 +326,7 @@ g_value_peek_pointer (const GValue *value)
|
||||
/**
|
||||
* g_value_set_instance:
|
||||
* @value: An initialized #GValue structure.
|
||||
* @instance: the instance
|
||||
* @instance: (allow-none): the instance
|
||||
*
|
||||
* Sets @value from an instantiatable type via the
|
||||
* value_table's collect_value() function.
|
||||
|
@ -1172,7 +1172,7 @@ g_value_get_gtype (const GValue *value)
|
||||
/**
|
||||
* g_value_set_variant:
|
||||
* @value: a valid #GValue of type %G_TYPE_VARIANT
|
||||
* @variant: a #GVariant, or %NULL
|
||||
* @variant: (allow-none): a #GVariant, or %NULL
|
||||
*
|
||||
* Set the contents of a variant #GValue to @variant.
|
||||
* If the variant is floating, it is consumed.
|
||||
@ -1201,7 +1201,7 @@ g_value_set_variant (GValue *value,
|
||||
/**
|
||||
* g_value_take_variant:
|
||||
* @value: a valid #GValue of type %G_TYPE_VARIANT
|
||||
* @variant: a #GVariant, or %NULL
|
||||
* @variant: (allow-none): a #GVariant, or %NULL
|
||||
*
|
||||
* Set the contents of a variant #GValue to @variant, and takes over
|
||||
* the ownership of the caller's reference to @variant;
|
||||
|
Loading…
Reference in New Issue
Block a user