Primitive outputs have same limitations as continuous assignment.
This commit is contained in:
parent
38d851f04e
commit
c96598a429
12
elab_net.cc
12
elab_net.cc
|
|
@ -17,7 +17,7 @@
|
|||
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA
|
||||
*/
|
||||
#ifdef HAVE_CVS_IDENT
|
||||
#ident "$Id: elab_net.cc,v 1.114 2003/06/21 01:21:43 steve Exp $"
|
||||
#ident "$Id: elab_net.cc,v 1.115 2003/08/05 03:01:58 steve Exp $"
|
||||
#endif
|
||||
|
||||
# include "config.h"
|
||||
|
|
@ -1556,6 +1556,7 @@ NetNet* PEIdent::elaborate_lnet(Design*des, NetScope*scope,
|
|||
cerr << get_line() << ": error: memories (" << path_
|
||||
<< ") cannot be l-values in continuous "
|
||||
<< "assignments." << endl;
|
||||
des->errors += 1;
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
|
@ -1575,6 +1576,7 @@ NetNet* PEIdent::elaborate_lnet(Design*des, NetScope*scope,
|
|||
<< " is not defined in this context." << endl;
|
||||
cerr << get_line() << ": : Do you mean this? wire "
|
||||
<< path_ << " = <expr>;" << endl;
|
||||
des->errors += 1;
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
|
|
@ -1584,8 +1586,9 @@ NetNet* PEIdent::elaborate_lnet(Design*des, NetScope*scope,
|
|||
/* Don't allow registers as assign l-values. */
|
||||
if (sig->type() == NetNet::REG) {
|
||||
cerr << get_line() << ": error: reg " << sig->name()
|
||||
<< "; cannot be an L-value in continuous"
|
||||
<< " assignments." << endl;
|
||||
<< "; cannot be driven by primitives"
|
||||
<< " or continuous assignment." << endl;
|
||||
des->errors += 1;
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
|
@ -2323,6 +2326,9 @@ NetNet* PEUnary::elaborate_net(Design*des, NetScope*scope,
|
|||
|
||||
/*
|
||||
* $Log: elab_net.cc,v $
|
||||
* Revision 1.115 2003/08/05 03:01:58 steve
|
||||
* Primitive outputs have same limitations as continuous assignment.
|
||||
*
|
||||
* Revision 1.114 2003/06/21 01:21:43 steve
|
||||
* Harmless fixup of warnings.
|
||||
*
|
||||
|
|
|
|||
|
|
@ -17,7 +17,7 @@
|
|||
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA
|
||||
*/
|
||||
#ifdef HAVE_CVS_IDENT
|
||||
#ident "$Id: elaborate.cc,v 1.284 2003/07/02 04:19:16 steve Exp $"
|
||||
#ident "$Id: elaborate.cc,v 1.285 2003/08/05 03:01:58 steve Exp $"
|
||||
#endif
|
||||
|
||||
# include "config.h"
|
||||
|
|
@ -446,7 +446,9 @@ void PGBuiltin::elaborate(Design*des, NetScope*scope) const
|
|||
|
||||
for (unsigned idx = 0 ; idx < pin_count() ; idx += 1) {
|
||||
const PExpr*ex = pin(idx);
|
||||
NetNet*sig = ex->elaborate_net(des, scope, 0, 0, 0, 0);
|
||||
NetNet*sig = (idx == 0)
|
||||
? ex->elaborate_lnet(des, scope, true)
|
||||
: ex->elaborate_net(des, scope, 0, 0, 0, 0);
|
||||
if (sig == 0)
|
||||
continue;
|
||||
|
||||
|
|
@ -2577,6 +2579,9 @@ Design* elaborate(list<const char*>roots)
|
|||
|
||||
/*
|
||||
* $Log: elaborate.cc,v $
|
||||
* Revision 1.285 2003/08/05 03:01:58 steve
|
||||
* Primitive outputs have same limitations as continuous assignment.
|
||||
*
|
||||
* Revision 1.284 2003/07/02 04:19:16 steve
|
||||
* Elide empty begin-end in conditionals.
|
||||
*
|
||||
|
|
|
|||
Loading…
Reference in New Issue