mirror of
https://github.com/steveicarus/iverilog.git
synced 2026-08-29 01:03:29 +02:00
Handle system functions that return enumerations.
There are a few internal system functions that return enumeration values, and the type checker needs to properly account for that.
This commit is contained in:
+3
-3
@@ -1359,12 +1359,12 @@ NetNet* NetESFunc::synthesize(Design*des, NetScope*scope, NetExpr*root)
|
||||
}
|
||||
|
||||
NetEvWait*trigger = 0;
|
||||
if (nparms_ == 0) {
|
||||
if (parms_.size() == 0) {
|
||||
trigger = make_func_trigger(des, scope, root);
|
||||
}
|
||||
|
||||
NetSysFunc*net = new NetSysFunc(scope, scope->local_symbol(),
|
||||
def, 1+nparms_, trigger);
|
||||
def, 1+parms_.size(), trigger);
|
||||
net->set_line(*this);
|
||||
des->add_node(net);
|
||||
|
||||
@@ -1378,7 +1378,7 @@ NetNet* NetESFunc::synthesize(Design*des, NetScope*scope, NetExpr*root)
|
||||
connect(net->pin(0), osig->pin(0));
|
||||
|
||||
unsigned errors = 0;
|
||||
for (unsigned idx = 0 ; idx < nparms_ ; idx += 1) {
|
||||
for (unsigned idx = 0 ; idx < parms_.size() ; idx += 1) {
|
||||
NetNet*tmp = parms_[idx]->synthesize(des, scope, root);
|
||||
if (tmp == 0) {
|
||||
cerr << get_fileline() << ": error: Unable to elaborate "
|
||||
|
||||
Reference in New Issue
Block a user