[vala] girparser: Accept function in record, boxed, union, enumeration
- From: JÃrg Billeter <juergbi src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [vala] girparser: Accept function in record, boxed, union, enumeration
- Date: Mon, 15 Aug 2011 14:27:13 +0000 (UTC)
commit 486ba787cb554b25b7f4564ca824d0b92b0c9b61
Author: JÃrg Billeter <j bitron ch>
Date: Mon Aug 15 16:12:31 2011 +0200
girparser: Accept function in record, boxed, union, enumeration
Used by gobject-introspection 1.29.17+. This commit ignores the
function elements but they could replace our own static method
detection in the future.
vala/valagirparser.vala | 8 ++++++++
1 files changed, 8 insertions(+), 0 deletions(-)
---
diff --git a/vala/valagirparser.vala b/vala/valagirparser.vala
index 847efb8..c440705 100644
--- a/vala/valagirparser.vala
+++ b/vala/valagirparser.vala
@@ -1935,6 +1935,8 @@ public class Vala.GirParser : CodeVisitor {
parse_enumeration_member ();
calculate_common_prefix (ref common_prefix, old_current.get_cname ());
}
+ } else if (reader.name == "function") {
+ skip_element ();
} else {
// error
Report.error (get_current_src (), "unknown child element `%s' in `%s'".printf (reader.name, element_name));
@@ -2304,6 +2306,8 @@ public class Vala.GirParser : CodeVisitor {
parse_constructor ();
} else if (reader.name == "method") {
parse_method ("method");
+ } else if (reader.name == "function") {
+ skip_element ();
} else if (reader.name == "union") {
parse_union ();
} else {
@@ -2750,6 +2754,8 @@ public class Vala.GirParser : CodeVisitor {
parse_constructor ();
} else if (reader.name == "method") {
parse_method ("method");
+ } else if (reader.name == "function") {
+ skip_element ();
} else if (reader.name == "union") {
parse_union ();
} else {
@@ -2792,6 +2798,8 @@ public class Vala.GirParser : CodeVisitor {
parse_constructor ();
} else if (reader.name == "method") {
parse_method ("method");
+ } else if (reader.name == "function") {
+ skip_element ();
} else if (reader.name == "record") {
parse_record ();
} else {
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]