From db4088828b690a82372325268c9eadff7823da1a Mon Sep 17 00:00:00 2001 From: Cesar Strauss Date: Sun, 27 Sep 2020 18:31:29 -0300 Subject: [PATCH] Report cxxsim selected, only when using the new API --- src/nmutil/sim_tmp_alternative.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/nmutil/sim_tmp_alternative.py b/src/nmutil/sim_tmp_alternative.py index e615ad5..b0ed141 100644 --- a/src/nmutil/sim_tmp_alternative.py +++ b/src/nmutil/sim_tmp_alternative.py @@ -53,12 +53,12 @@ def Simulator(*args, **kwargs): def is_engine_cxxsim(): """Returns ``True`` if the selected engine is cxxsim""" - return nmigen_sim_environ_variable == "cxxsim" + return detected_new_api and nmigen_sim_environ_variable == "cxxsim" def is_engine_pysim(): """Returns ``True`` if the selected engine is pysim""" - return nmigen_sim_environ_variable == "pysim" + return not detected_new_api or nmigen_sim_environ_variable == "pysim" nmigen_sim_top_module = "top." if is_engine_pysim() else "" -- 2.30.2