Commit 22e30390 authored by Adrien Bustany's avatar Adrien Bustany

GIR parser: Always add the cname attribute to generated methods

parent ca674a7f
......@@ -867,6 +867,7 @@ public class Vala.GirParser : CodeVisitor {
Method parse_method (string element_name) {
start_element (element_name);
string name = reader.get_attribute ("name");
string cname = reader.get_attribute ("c:identifier");
string throws_string = reader.get_attribute ("throws");
string invoker = reader.get_attribute ("invoker");
next ();
......@@ -878,6 +879,9 @@ public class Vala.GirParser : CodeVisitor {
}
var m = new Method (name, return_type, get_current_src ());
m.access = SymbolAccessibility.PUBLIC;
if (cname != null) {
m.set_cname (cname);
}
if (element_name == "virtual-method" || element_name == "callback") {
m.is_virtual = true;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment