mirror of
https://github.com/YosysHQ/yosys
synced 2025-08-04 10:20:24 +00:00
Remove log_str()
functions and convert their log_signal()
users to return std::string
This is a small but easy step towards removing the `log_id_cache`. See issue #5210.
This commit is contained in:
parent
7b0c1fe491
commit
ec3f384dca
6 changed files with 28 additions and 39 deletions
|
@ -635,15 +635,15 @@ private:
|
|||
}
|
||||
}
|
||||
}
|
||||
void undriven(const char *name) {
|
||||
void undriven(const std::string& name) {
|
||||
log_error("The design contains an undriven signal %s. This is not supported by the functional backend. "
|
||||
"Call setundef with appropriate options to avoid this error.\n", name);
|
||||
"Call setundef with appropriate options to avoid this error.\n", name.c_str());
|
||||
}
|
||||
// we perform this check separately to give better error messages that include the wire or port name
|
||||
void check_undriven(DriveSpec const& spec, std::string const& name) {
|
||||
for(auto const &chunk : spec.chunks())
|
||||
if(chunk.is_none())
|
||||
undriven(name.c_str());
|
||||
undriven(name);
|
||||
}
|
||||
public:
|
||||
void process_queue()
|
||||
|
@ -706,11 +706,11 @@ public:
|
|||
factory.update_pending(pending, node);
|
||||
} else if (chunk.is_multiple()) {
|
||||
log_error("Signal %s has multiple drivers. This is not supported by the functional backend. "
|
||||
"If tristate drivers are used, call tristate -formal to avoid this error.\n", log_signal(chunk));
|
||||
"If tristate drivers are used, call tristate -formal to avoid this error.\n", log_signal(chunk).c_str());
|
||||
} else if (chunk.is_none()) {
|
||||
undriven(log_signal(chunk));
|
||||
} else {
|
||||
log_error("unhandled drivespec: %s\n", log_signal(chunk));
|
||||
log_error("unhandled drivespec: %s\n", log_signal(chunk).c_str());
|
||||
log_abort();
|
||||
}
|
||||
} else {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue