Decompiler fixes + decompiling (#276)

* decomp pad

* more decompilation

* update

* fix test name
This commit is contained in:
water111
2021-02-22 09:36:30 -05:00
committed by GitHub
parent ac24b2ab15
commit 5ec9a91eb9
48 changed files with 2567 additions and 530 deletions
+8 -3
View File
@@ -229,9 +229,14 @@ std::string write_from_top_level(const Function& top_level,
auto deftype_match_result = match(deftype_matcher, &f);
if (deftype_match_result.matched) {
auto& name = deftype_match_result.maps.strings.at(type_name);
result += fmt::format(";; definition of type {}\n", name);
result += dts.ts.generate_deftype(dts.ts.lookup_type(name));
result += "\n\n";
if (dts.ts.fully_defined_type_exists(name)) {
result += fmt::format(";; definition of type {}\n", name);
result += dts.ts.generate_deftype(dts.ts.lookup_type(name));
result += "\n\n";
} else {
result +=
fmt::format(";; type {} defintion, but it is unknown to the decompiler\n\n", name);
}
something_matched = true;
}
}