Improve error messages when multiple drivers are detected.
Distinguish between nets declared as uwires and variables.
This commit is contained in:
parent
65f552aba3
commit
cd2d4e9287
|
|
@ -876,8 +876,12 @@ NetNet* PEIdent::elaborate_lnet_common_(Design*des, NetScope*scope,
|
||||||
long wcount = widx_flag ? 1 : sig->pin_count();
|
long wcount = widx_flag ? 1 : sig->pin_count();
|
||||||
for (long idx = 0; idx < wcount; idx += 1) {
|
for (long idx = 0; idx < wcount; idx += 1) {
|
||||||
if (sig->test_and_set_part_driver(midx, lidx, widx + idx)) {
|
if (sig->test_and_set_part_driver(midx, lidx, widx + idx)) {
|
||||||
cerr << get_fileline() << ": error: Unresolved net/uwire "
|
cerr << get_fileline() << ": error: ";
|
||||||
<< sig->name() << " cannot have multiple drivers." << endl;
|
if (sig->coerced_to_uwire())
|
||||||
|
cerr << "Variable '";
|
||||||
|
else
|
||||||
|
cerr << "Unresolved wire '";
|
||||||
|
cerr << sig->name() << "' cannot have multiple drivers." << endl;
|
||||||
if (debug_elaborate) {
|
if (debug_elaborate) {
|
||||||
cerr << get_fileline() << ": : Overlap in "
|
cerr << get_fileline() << ": : Overlap in "
|
||||||
<< "[" << midx << ":" << lidx << "] (canonical)"
|
<< "[" << midx << ":" << lidx << "] (canonical)"
|
||||||
|
|
|
||||||
|
|
@ -1,2 +1,2 @@
|
||||||
ivltests/br_gh1087a.v:6: error: Unresolved net/uwire r cannot have multiple drivers.
|
ivltests/br_gh1087a.v:6: error: Unresolved wire 'r' cannot have multiple drivers.
|
||||||
1 error(s) during elaboration.
|
1 error(s) during elaboration.
|
||||||
|
|
|
||||||
|
|
@ -1,2 +1,2 @@
|
||||||
ivltests/br_gh1087b.v:6: error: Unresolved net/uwire b cannot have multiple drivers.
|
ivltests/br_gh1087b.v:6: error: Unresolved wire 'b' cannot have multiple drivers.
|
||||||
1 error(s) during elaboration.
|
1 error(s) during elaboration.
|
||||||
|
|
|
||||||
|
|
@ -1,2 +1,2 @@
|
||||||
./ivltests/uwire_fail.v:5: error: Unresolved net/uwire two cannot have multiple drivers.
|
./ivltests/uwire_fail.v:5: error: Unresolved wire 'two' cannot have multiple drivers.
|
||||||
1 error(s) during elaboration.
|
1 error(s) during elaboration.
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue