Internals: Fix same() called outside of sameTree (#4561).

This commit is contained in:
Wilson Snyder
2023-10-18 17:36:21 -04:00
parent 8720841c48
commit b7233d063f
6 changed files with 14 additions and 8 deletions
+1 -1
View File
@@ -135,7 +135,7 @@ class SliceVisitor final : public VNVisitor {
const AstUnpackArrayDType* const itemDTypep
= VN_CAST(itemRawDTypep, UnpackArrayDType);
if (!itemDTypep
|| !expectedItemDTypep->same(itemDTypep->subDTypep()->skipRefp())) {
|| !expectedItemDTypep->isSame(itemDTypep->subDTypep()->skipRefp())) {
if (!m_assignError) {
itemp->v3error("Item is incompatible with the array type.");
}