mirror of
https://github.com/verilator/verilator.git
synced 2026-09-02 02:38:15 +02:00
Normalize types in constraints (#5407)
Signed-off-by: Krzysztof Bieganski <[email protected]>
This commit is contained in:
+2
-2
@@ -551,7 +551,7 @@ class ConstraintExprVisitor final : public VNVisitor {
|
||||
if (!exprsp->nextp()) return exprsp;
|
||||
|
||||
std::ostringstream fmt;
|
||||
fmt << "(and";
|
||||
fmt << "(bvand";
|
||||
for (AstNode* itemp = exprsp; itemp; itemp = itemp->nextp()) fmt << " %@";
|
||||
fmt << ')';
|
||||
return new AstSFormatF{fl, fmt.str(), false, exprsp};
|
||||
@@ -695,7 +695,7 @@ class ConstraintExprVisitor final : public VNVisitor {
|
||||
AstNode* const cstmtp = new AstText{fl, "ret += \" \" + "};
|
||||
cstmtp->addNext(itemp);
|
||||
cstmtp->addNext(new AstText{fl, ";"});
|
||||
AstNode* const exprsp = new AstText{fl, "([&]{ std::string ret = \"(and\";"};
|
||||
AstNode* const exprsp = new AstText{fl, "([&]{ std::string ret = \"(bvand\";"};
|
||||
exprsp->addNext(new AstBegin{
|
||||
fl, "",
|
||||
new AstForeach{fl, nodep->arrayp()->unlinkFrBack(), new AstCStmt{fl, cstmtp}},
|
||||
|
||||
Reference in New Issue
Block a user