mirror of
https://github.com/verilator/verilator.git
synced 2026-10-06 01:54:01 +02:00
Do not use function locals in SenExprBuilder (#5822)
Function locals are not safe here because we might need to split up the generated function. V3Localize can fix them later if safe.
This commit is contained in:
@@ -752,14 +752,6 @@ const TriggerKit createTriggers(AstNetlist* netlistp, AstCFunc* const initFuncp,
|
||||
funcp->stmtsp()->addHereThisAsNext(nodep);
|
||||
}
|
||||
}
|
||||
const auto& locals = senExprBuilder.getAndClearLocals();
|
||||
if (!locals.empty()) {
|
||||
UASSERT_OBJ(funcp->stmtsp(), funcp,
|
||||
"No statements in trigger eval function, but there are locals");
|
||||
for (AstVar* const nodep : vlstd::reverse_view(locals)) {
|
||||
funcp->stmtsp()->addHereThisAsNext(nodep);
|
||||
}
|
||||
}
|
||||
|
||||
// Add the initialization statements
|
||||
if (initialTrigsp) {
|
||||
|
||||
Reference in New Issue
Block a user