mirror of
https://github.com/verilator/verilator.git
synced 2026-10-06 10:03:44 +02:00
Fix wildcard equality and inside operators for non-fourstate expressions (#5673)
This commit is contained in:
+5
-3
@@ -237,9 +237,11 @@ class UnknownVisitor final : public VNVisitor {
|
||||
AstNodeExpr* const rhsp = nodep->rhsp()->unlinkFrBack();
|
||||
AstNodeExpr* newp;
|
||||
if (!VN_IS(rhsp, Const)) {
|
||||
nodep->v3warn(E_UNSUPPORTED, "Unsupported: RHS of ==? or !=? must be "
|
||||
"constant to be synthesizable"); // Says spec.
|
||||
// Replace with anything that won't cause more errors
|
||||
if (rhsp->dtypep()->isFourstate()) {
|
||||
nodep->v3warn(
|
||||
E_UNSUPPORTED,
|
||||
"Unsupported: RHS of ==? or !=? is fourstate but not a constant");
|
||||
}
|
||||
newp = new AstEq{nodep->fileline(), lhsp, rhsp};
|
||||
} else {
|
||||
// X or Z's become mask, ala case statements.
|
||||
|
||||
Reference in New Issue
Block a user