3
0
Fork 0
mirror of https://github.com/YosysHQ/yosys synced 2026-02-26 02:01:28 +00:00
This commit is contained in:
KrystalDelusion 2025-12-18 09:00:45 +01:00 committed by GitHub
commit ae3f45f9f4
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
13 changed files with 911 additions and 202 deletions

View file

@ -766,16 +766,14 @@ struct HelpPass : public Pass {
// init json
json.begin_object();
json.entry("version", "Yosys command reference");
json.entry("generator", yosys_version_str);
json.entry("generator", yosys_maybe_version());
bool raise_error = false;
std::map<string, vector<string>> groups;
json.name("cmds"); json.begin_object();
// iterate over commands
for (auto &it : pass_register) {
auto name = it.first;
auto pass = it.second;
for (auto &[name, pass] : pass_register) {
auto title = pass->short_help;
auto cmd_help = PrettyHelp();
@ -890,7 +888,7 @@ struct HelpPass : public Pass {
if (current_buffer.empty())
current_buffer = stripped_line;
else if (current_state == PUState_signature && IsIndent)
current_buffer += stripped_line;
current_buffer += " " + stripped_line;
else if (current_state == PUState_none) {
current_buffer += (blank_lines > 0 ? "\n\n" : "\n") + line;
} else