summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRico Tzschichholz <ricotz@ubuntu.com>2018-04-14 00:59:44 +0200
committerRico Tzschichholz <ricotz@ubuntu.com>2018-04-14 01:05:33 +0200
commitdbc8b1a3d6a5aaa7a682d09eb533752e9e2ef0b1 (patch)
tree986d3deaf6c6b18cbfbf3aa68b0f30e1cb1645d8
parentf1d5c67aaed76f8f322ec3c77cb65dedb348e287 (diff)
downloadvala-dbc8b1a3d6a5aaa7a682d09eb533752e9e2ef0b1.tar.gz
girparser: Add support for NoAccessorMethod metadata
-rw-r--r--vala/valagirparser.vala5
1 files changed, 5 insertions, 0 deletions
diff --git a/vala/valagirparser.vala b/vala/valagirparser.vala
index 24d1ea50f..33bbfd1d2 100644
--- a/vala/valagirparser.vala
+++ b/vala/valagirparser.vala
@@ -86,6 +86,7 @@ public class Vala.GirParser : CodeVisitor {
RETURNS_MODIFIED_POINTER,
DELEGATE_TARGET_CNAME,
FINISH_VFUNC_NAME,
+ NO_ACCESSOR_METHOD,
CNAME;
public static ArgumentType? from_string (string name) {
@@ -1071,6 +1072,10 @@ public class Vala.GirParser : CodeVisitor {
}
}
+ if (metadata.has_argument (ArgumentType.NO_ACCESSOR_METHOD)) {
+ prop.set_attribute ("NoAccessorMethod", metadata.get_bool (ArgumentType.NO_ACCESSOR_METHOD));
+ }
+
if (prop.get_attribute ("NoAccessorMethod") != null) {
// gobject defaults
if (prop.get_accessor != null) {