mirror of
https://github.com/YosysHQ/yosys
synced 2025-09-18 07:31:31 +00:00
Remove .c_str() calls from log()/log_error()
There are some leftovers, but this is an easy regex-based approach that removes most of them.
This commit is contained in:
parent
c2291c10a6
commit
e0ae7b7af4
140 changed files with 623 additions and 623 deletions
|
@ -10,7 +10,7 @@ struct MyPass : public Pass {
|
|||
{
|
||||
log("Arguments to my_cmd:\n");
|
||||
for (auto &arg : args)
|
||||
log(" %s\n", arg.c_str());
|
||||
log(" %s\n", arg);
|
||||
|
||||
log("Modules in current design:\n");
|
||||
for (auto mod : design->modules())
|
||||
|
|
|
@ -16,7 +16,7 @@ struct FunctionalDummyBackend : public Backend {
|
|||
|
||||
for (auto module : design->selected_modules())
|
||||
{
|
||||
log("Processing module `%s`.\n", module->name.c_str());
|
||||
log("Processing module `%s`.\n", module->name);
|
||||
|
||||
// convert module to FunctionalIR
|
||||
auto ir = Functional::IR::from_module(module);
|
||||
|
|
|
@ -45,9 +45,9 @@ creates a bijective map from ``K`` to the integers. For example:
|
|||
log("%d\n", si("world")); // will print 43
|
||||
log("%d\n", si.at("world")); // will print 43
|
||||
log("%d\n", si.at("dummy")); // will throw exception
|
||||
log("%s\n", si[42].c_str())); // will print hello
|
||||
log("%s\n", si[43].c_str())); // will print world
|
||||
log("%s\n", si[44].c_str())); // will throw exception
|
||||
log("%s\n", si[42])); // will print hello
|
||||
log("%s\n", si[43])); // will print world
|
||||
log("%s\n", si[44])); // will throw exception
|
||||
|
||||
It is not possible to remove elements from an idict.
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue