From ad329612fd834eaa193acfa81f540af175c8ed5d Mon Sep 17 00:00:00 2001 From: Wilson Snyder Date: Fri, 1 Sep 2023 20:13:20 -0400 Subject: [PATCH] Internals: Remove unnecessary cloneTree. --- src/V3Const.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/V3Const.cpp b/src/V3Const.cpp index 0771629b4..ad8795e55 100644 --- a/src/V3Const.cpp +++ b/src/V3Const.cpp @@ -1799,7 +1799,7 @@ private: UASSERT_OBJ((rstart + rwidth) == lstart, nodep, "tried to merge two selects which are not adjacent"); AstSel* const newselp = new AstSel{ - lselp->fromp()->fileline(), rselp->fromp()->cloneTree(false), rstart, lwidth + rwidth}; + lselp->fromp()->fileline(), rselp->fromp()->unlinkFrBack(), rstart, lwidth + rwidth}; UINFO(5, "merged two adjacent sel " << lselp << " and " << rselp << " to one " << newselp << endl);