Don't delete L-value concat signals and give a better error message.
This patch removes the code that was deleting the signals in an L-value concat if the concatenation failed to elaborate. This is incorrect since the signal could be used in another context that is processed later. The error message when an output/inout port fails to elaborate was also improved to give the expression that is connected to the port.
This commit is contained in:
parent
468fd3d683
commit
fc3118bd7f
|
|
@ -84,12 +84,7 @@ NetNet* PEConcat::elaborate_lnet_common_(Design*des, NetScope*scope,
|
|||
|
||||
}
|
||||
|
||||
/* If any of the sub expressions failed to elaborate, then
|
||||
delete all those that did and abort myself. */
|
||||
if (errors) {
|
||||
for (unsigned idx = 0 ; idx < nets.count() ; idx += 1) {
|
||||
if (nets[idx]) delete nets[idx];
|
||||
}
|
||||
des->errors += errors;
|
||||
return 0;
|
||||
}
|
||||
|
|
|
|||
10
elaborate.cc
10
elaborate.cc
|
|
@ -1411,8 +1411,9 @@ void PGModule::elaborate_mod_(Design*des, Module*rmod, NetScope*scope) const
|
|||
<< "Inout port expression must support "
|
||||
<< "continuous assignment." << endl;
|
||||
cerr << pins[idx]->get_fileline() << ": : "
|
||||
<< "Port of " << rmod->mod_name()
|
||||
<< " is " << rmod->ports[idx]->name << endl;
|
||||
<< "Port " << rmod->ports[idx]->name << " of "
|
||||
<< rmod->mod_name() << " is connected to "
|
||||
<< *pins[idx] << endl;
|
||||
des->errors += 1;
|
||||
continue;
|
||||
}
|
||||
|
|
@ -1457,8 +1458,9 @@ void PGModule::elaborate_mod_(Design*des, Module*rmod, NetScope*scope) const
|
|||
<< "Output port expression must support "
|
||||
<< "continuous assignment." << endl;
|
||||
cerr << pins[idx]->get_fileline() << ": : "
|
||||
<< "Port of " << rmod->mod_name()
|
||||
<< " is " << rmod->ports[idx]->name << endl;
|
||||
<< "Port " << rmod->ports[idx]->name << " of "
|
||||
<< rmod->mod_name() << " is connected to "
|
||||
<< *pins[idx] << endl;
|
||||
des->errors += 1;
|
||||
continue;
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue