Commit 4e603584 authored by Evan Nemerson's avatar Evan Nemerson

girwriter: fall back on gir_namespace if GIR name is not available

parent f30503f7
......@@ -1338,7 +1338,15 @@ public class Vala.GIRWriter : CodeVisitor {
}
private string? get_full_gir_name (Symbol sym) {
var gir_name = sym.get_attribute_string ("GIR", "name") ?? sym.name;
string? gir_name = sym.get_attribute_string ("GIR", "name");
if (gir_name == null && sym is Namespace) {
gir_name = sym.get_attribute_string ("CCode", "gir_namespace");
}
if (gir_name == null) {
gir_name = sym.name;
}
if (sym.parent_symbol == null) {
return gir_name;
}
......
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