From: Rico Tzschichholz Date: Mon, 1 Dec 2014 13:51:32 +0000 (+0100) Subject: glib-2.0: unowned array-elements are supported since 0.26, so use it X-Git-Tag: 0.27.1~39 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=9f86edc7be0f28f875b1c42637cd214232926eeb;p=thirdparty%2Fvala.git glib-2.0: unowned array-elements are supported since 0.26, so use it --- diff --git a/vapi/glib-2.0.vapi b/vapi/glib-2.0.vapi index 01d3c714c..fd8ef2f89 100644 --- a/vapi/glib-2.0.vapi +++ b/vapi/glib-2.0.vapi @@ -4180,6 +4180,9 @@ namespace GLib { [CCode (cname = "g_hash_table_insert")] public void @set (owned K key, owned V value); public List get_keys (); +#if VALA_0_26 + public (unowned K)[] get_keys_as_array (); +#endif public List get_values (); public void @foreach (HFunc func); [CCode (cname = "g_hash_table_foreach")] @@ -4904,27 +4907,35 @@ namespace GLib { public Variant.strv (string[] value); [CCode (array_length_type = "size_t")] +#if VALA_0_26 + public (unowned string)[] get_strv (); +#else public string*[] get_strv (); +#endif [CCode (array_length_type = "size_t")] public string[] dup_strv (); public Variant.bytestring_array (string[] value); [CCode (array_length_type = "size_t")] +#if VALA_0_26 + public (unowned string)[] get_bytestring_array (); +#else public string*[] get_bytestring_array (); +#endif [CCode (array_length_type = "size_t")] public string[] dup_bytestring_array (); - #if GLIB_2_30 +#if GLIB_2_30 public Variant.objv (string[] value); [CCode (array_length_type = "size_t")] - #if VALA_0_26 +#if VALA_0_26 public (unowned string)[] get_objv (); - #else +#else public string*[] get_objv (); - #endif +#endif [CCode (array_length_type = "size_t")] public string[] dup_objv (); - #endif +#endif public Variant (string format, ...); // note: the function changes its behaviour when end_ptr is null, so 'out char *' is wrong