mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2025-01-11 15:06:14 +01:00
gparamspecs: Tidy up a precondition
Move the `if` into the precondition assertion, eliminating one line of code and making the function preconditions clearer to static analysers. Signed-off-by: Philip Withnall <pwithnall@endlessos.org>
This commit is contained in:
parent
96f4c2b095
commit
f157c7d0d3
@ -2639,8 +2639,7 @@ g_param_spec_value_array (const gchar *name,
|
|||||||
{
|
{
|
||||||
GParamSpecValueArray *aspec;
|
GParamSpecValueArray *aspec;
|
||||||
|
|
||||||
if (element_spec)
|
g_return_val_if_fail (element_spec == NULL || G_IS_PARAM_SPEC (element_spec), NULL);
|
||||||
g_return_val_if_fail (G_IS_PARAM_SPEC (element_spec), NULL);
|
|
||||||
|
|
||||||
aspec = g_param_spec_internal (G_TYPE_PARAM_VALUE_ARRAY,
|
aspec = g_param_spec_internal (G_TYPE_PARAM_VALUE_ARRAY,
|
||||||
name,
|
name,
|
||||||
|
Loading…
Reference in New Issue
Block a user