[vala/0.34] girparser: Allow change of parameter names
- From: Rico Tzschichholz <ricotz src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [vala/0.34] girparser: Allow change of parameter names
- Date: Sat, 9 Dec 2017 13:42:04 +0000 (UTC)
commit 00e88fcfb0dff92ffb5e59d44d4696c572dca125
Author: Rico Tzschichholz <ricotz ubuntu com>
Date: Sat Dec 2 18:31:03 2017 +0100
girparser: Allow change of parameter names
vala/valagirparser.vala | 5 ++++-
1 files changed, 4 insertions(+), 1 deletions(-)
---
diff --git a/vala/valagirparser.vala b/vala/valagirparser.vala
index d9323a3..5d54b5e 100644
--- a/vala/valagirparser.vala
+++ b/vala/valagirparser.vala
@@ -2426,7 +2426,10 @@ public class Vala.GirParser : CodeVisitor {
Report.error (get_current_src (), "expected start element of `parameter' or
`instance-parameter'");
}
start_element (element_type);
- string name = reader.get_attribute ("name");
+ var name = metadata.get_string (ArgumentType.NAME);
+ if (name == null) {
+ name = reader.get_attribute ("name");
+ }
if (name == null) {
name = default_name;
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]