From 3bcd42dc8f1a5769272e591a903a987ac01302b4 Mon Sep 17 00:00:00 2001 From: Nick Gasson Date: Tue, 29 Jul 2008 19:39:20 +0100 Subject: [PATCH] Fix case where logic device has no valid output --- tgt-vhdl/scope.cc | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/tgt-vhdl/scope.cc b/tgt-vhdl/scope.cc index dd984dec1..158ad0091 100644 --- a/tgt-vhdl/scope.cc +++ b/tgt-vhdl/scope.cc @@ -162,7 +162,16 @@ void draw_nexus(ivl_nexus_t nexus) } else { cout << "...has no signal!" << endl; - assert(false); + + // Create a temporary signal to connect it to the nexus + vhdl_type *type = + vhdl_type::type_for(ivl_logic_width(log), false); + + ostringstream ss; + ss << "LO" << ivl_logic_basename(log); + vhdl_scope->add_decl(new vhdl_signal_decl(ss.str().c_str(), type)); + + link_scope_to_nexus_tmp(priv, vhdl_scope, ss.str()); } } else if ((lpm = ivl_nexus_ptr_lpm(nexus_ptr))) {