[vala] girparser: No support for fixed-size array as return-value
- From: Rico Tzschichholz <ricotz src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [vala] girparser: No support for fixed-size array as return-value
- Date: Thu, 24 Nov 2016 08:30:43 +0000 (UTC)
commit 38e968db9c0417f3923932a104006768f45805d4
Author: Rico Tzschichholz <ricotz ubuntu com>
Date: Thu Nov 24 09:23:40 2016 +0100
girparser: No support for fixed-size array as return-value
Due to the special syntax for those arrays it lead to omitting the
array-qualifier and therefore generating broken bindings.
vala/valagirparser.vala | 8 ++++++++
1 files changed, 8 insertions(+), 0 deletions(-)
---
diff --git a/vala/valagirparser.vala b/vala/valagirparser.vala
index 122e0ce..892afb4 100644
--- a/vala/valagirparser.vala
+++ b/vala/valagirparser.vala
@@ -2382,6 +2382,14 @@ public class Vala.GirParser : CodeVisitor {
type.nullable = true;
}
type = element_get_type (type, true, ref no_array_length, ref array_null_terminated);
+
+ // FIXME No support for fixed-size array as return-value
+ var array_type = type as ArrayType;
+ if (array_type != null && array_type.fixed_length) {
+ array_type.fixed_length = false;
+ array_type.length = null;
+ }
+
end_element ("return-value");
return type;
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]