odin query

Output .json file containing information about the program
This commit is contained in:
gingerBill
2019-05-25 20:24:19 +01:00
parent f5fdd031f9
commit 458ec5922e
12 changed files with 1018 additions and 86 deletions

View File

@@ -2765,7 +2765,13 @@ gbString write_type_to_string(gbString str, Type *type) {
case Type_Generic:
if (type->Generic.name.len == 0) {
str = gb_string_appendc(str, "type");
if (type->Generic.entity != nullptr) {
String name = type->Generic.entity->token.string;
str = gb_string_append_rune(str, '$');
str = gb_string_append_length(str, name.text, name.len);
} else {
str = gb_string_appendc(str, "type");
}
} else {
String name = type->Generic.name;
str = gb_string_append_rune(str, '$');