readline: fix escaping in autocomplete

This commit is contained in:
Emil J. Tywoniak
2026-10-02 18:42:02 +02:00
parent 0841ff7a24
commit 8304dec553
+3 -3
View File
@@ -942,7 +942,7 @@ static char *readline_obj_generator(const char *text, int state)
if (design->selected_active_module.empty())
{
for (auto mod : design->modules()) {
std::string mod_name = mod->name.str();
std::string mod_name = mod->name.unescape();
if (mod_name.compare(0, len, text) == 0)
obj_names.push_back(strdup(mod_name.c_str()));
}
@@ -956,7 +956,7 @@ static char *readline_obj_generator(const char *text, int state)
obj_names.push_back(strdup(w->name.unescape().c_str()));
for (auto &it : module->memories) {
std::string mem_name = design->twines.str(it.first);
std::string mem_name = design->twines.unescaped_str(it.first);
if (mem_name.compare(0, len, text) == 0)
obj_names.push_back(strdup(mem_name.c_str()));
}
@@ -966,7 +966,7 @@ static char *readline_obj_generator(const char *text, int state)
obj_names.push_back(strdup(cell->name.unescape().c_str()));
for (auto &it : module->processes) {
std::string proc_name = design->twines.str(it.first);
std::string proc_name = design->twines.unescaped_str(it.first);
if (proc_name.compare(0, len, text) == 0)
obj_names.push_back(strdup(proc_name.c_str()));
}