mirror of
https://github.com/verilator/verilator.git
synced 2025-01-23 23:04:14 +00:00
Fix coredump from increment patch (#2391)
This commit is contained in:
parent
c3271aa891
commit
ef71576825
@ -190,7 +190,8 @@ private:
|
|||||||
// Prepare a temporary variable
|
// Prepare a temporary variable
|
||||||
FileLine* fl = backp->fileline();
|
FileLine* fl = backp->fileline();
|
||||||
string name = string("__Vincrement") + cvtToStr(++m_modIncrementsNum);
|
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
|
// Declare the variable
|
||||||
insertBeforeStmt(nodep, varp);
|
insertBeforeStmt(nodep, varp);
|
||||||
|
Loading…
Reference in New Issue
Block a user