[vala] glib-2.0: unowned array-elements are supported since 0.26, so use it
- From: Rico Tzschichholz <ricotz src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [vala] glib-2.0: unowned array-elements are supported since 0.26, so use it
- Date: Mon, 1 Dec 2014 13:53:38 +0000 (UTC)
commit 9f86edc7be0f28f875b1c42637cd214232926eeb
Author: Rico Tzschichholz <ricotz ubuntu com>
Date: Mon Dec 1 14:51:32 2014 +0100
glib-2.0: unowned array-elements are supported since 0.26, so use it
vapi/glib-2.0.vapi | 21 ++++++++++++++++-----
1 files changed, 16 insertions(+), 5 deletions(-)
---
diff --git a/vapi/glib-2.0.vapi b/vapi/glib-2.0.vapi
index 01d3c71..fd8ef2f 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<unowned K> get_keys ();
+#if VALA_0_26
+ public (unowned K)[] get_keys_as_array ();
+#endif
public List<unowned V> get_values ();
public void @foreach (HFunc<K,V> 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
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]