1
0
mirror of synced 2026-01-29 05:21:15 +00:00

Fixed issue when using a python plugin in the yosys shell

This commit is contained in:
Benedikt Tutzer
2018-08-20 14:44:03 +02:00
parent d79a2808cf
commit 5864db3c2b
3 changed files with 28 additions and 4 deletions

View File

@@ -2783,10 +2783,13 @@ namespace YOSYS_PYTHON {
struct Initializer
{
Initializer() {
Yosys::log_streams.push_back(&std::cout);
Yosys::log_error_stderr = true;
Yosys::yosys_setup();
Yosys::yosys_banner();
if(!Yosys::yosys_already_setup())
{
Yosys::log_streams.push_back(&std::cout);
Yosys::log_error_stderr = true;
Yosys::yosys_setup();
Yosys::yosys_banner();
}
}
Initializer(Initializer const &) {}