From: Luca Bruno Date: Wed, 5 Jan 2011 11:33:04 +0000 (+0100) Subject: girparser: Fix parsing glib:boxed X-Git-Tag: 0.11.3~4 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=59dc89f0b409cb9ed45ce5007b82b7f0cc076432;p=thirdparty%2Fvala.git girparser: Fix parsing glib:boxed --- diff --git a/vala/valagirparser.vala b/vala/valagirparser.vala index 38c12d4aa..f3c614aff 100644 --- a/vala/valagirparser.vala +++ b/vala/valagirparser.vala @@ -1372,7 +1372,7 @@ public class Vala.GirParser : CodeVisitor { add_symbol_info (parse_callback ()); } else if (reader.name == "record") { if (reader.get_attribute ("glib:get-type") != null) { - add_symbol_info (parse_boxed ()); + add_symbol_info (parse_boxed ("record")); } else { add_symbol_info (parse_record ()); } @@ -1383,7 +1383,7 @@ public class Vala.GirParser : CodeVisitor { add_symbol_info (iface); interfaces.add (iface); } else if (reader.name == "glib:boxed") { - add_symbol_info (parse_boxed ()); + add_symbol_info (parse_boxed ("glib:boxed")); } else if (reader.name == "union") { add_symbol_info (parse_union ()); } else if (reader.name == "constant") { @@ -2408,7 +2408,8 @@ public class Vala.GirParser : CodeVisitor { return sig; } - Class parse_boxed () { + Class parse_boxed (string element_name) { + start_element (element_name); string name = reader.get_attribute ("name"); if (name == null) { name = reader.get_attribute ("glib:name"); @@ -2449,6 +2450,7 @@ public class Vala.GirParser : CodeVisitor { pop_metadata (); } + end_element (element_name); if (current_token != MarkupTokenType.END_ELEMENT) { // error