summaryrefslogtreecommitdiff
path: root/frontends/ast
diff options
context:
space:
mode:
authorClifford Wolf <clifford@clifford.at>2014-03-05 19:55:58 +0100
committerClifford Wolf <clifford@clifford.at>2014-03-05 19:55:58 +0100
commitd6a01fe412419d32ec5b0d91f9076849d1ed489d (patch)
treefc2511ec79944bd86448146f272325973400f4fc /frontends/ast
parentde7bd12004f24b7e9fff3ba1f253537704db4e44 (diff)
Fixed merging of compatible wire decls in AST frontend
Diffstat (limited to 'frontends/ast')
-rw-r--r--frontends/ast/simplify.cc5
1 files changed, 4 insertions, 1 deletions
diff --git a/frontends/ast/simplify.cc b/frontends/ast/simplify.cc
index 72d90e4a..a20aacff 100644
--- a/frontends/ast/simplify.cc
+++ b/frontends/ast/simplify.cc
@@ -206,10 +206,13 @@ bool AstNode::simplify(bool const_fold, bool at_zero, bool in_lvalue, int stage,
did_something = true;
delete node;
continue;
+ wires_are_incompatible:
+ if (stage > 1)
+ log_error("Incompatible re-declaration of wire %s at %s:%d.\n", node->str.c_str(), filename.c_str(), linenum);
+ continue;
}
this_wire_scope[node->str] = node;
}
- wires_are_incompatible:
if (node->type == AST_PARAMETER || node->type == AST_LOCALPARAM || node->type == AST_WIRE || node->type == AST_AUTOWIRE || node->type == AST_GENVAR ||
node->type == AST_MEMORY || node->type == AST_FUNCTION || node->type == AST_TASK || node->type == AST_CELL) {
backup_scope[node->str] = current_scope[node->str];