mirror of
https://github.com/verilator/verilator.git
synced 2026-10-05 17:43:31 +02:00
Fix coredump from increment patch (#2391)
This commit is contained in:
+2
-1
@@ -190,7 +190,8 @@ private:
|
||||
// Prepare a temporary variable
|
||||
FileLine* fl = backp->fileline();
|
||||
string name = string("__Vincrement") + cvtToStr(++m_modIncrementsNum);
|
||||
AstVar* varp = new AstVar(fl, AstVarType::BLOCKTEMP, name, varrefp->varp()->subDTypep());
|
||||
AstVar* varp = new AstVar(fl, AstVarType::BLOCKTEMP, name, VFlagChildDType(),
|
||||
varrefp->varp()->subDTypep()->cloneTree(true));
|
||||
|
||||
// Declare the variable
|
||||
insertBeforeStmt(nodep, varp);
|
||||
|
||||
Reference in New Issue
Block a user