Fix unpacked array passing to logic task arg error (#8148)

Signed-off-by: Pawel Klopotek <[email protected]>
This commit is contained in:
Pawel Klopotek
2026-08-19 08:04:28 +02:00
committed by GitHub
parent 86b7cfb05c
commit f5ae58ddab
3 changed files with 62 additions and 11 deletions
+5 -3
View File
@@ -7545,9 +7545,11 @@ class WidthVisitor final : public VNVisitor {
relinkHandle.relink(newp);
}
if (portp->isWritable()) V3LinkLValue::linkLValueSet(pinp);
if (VN_IS(pinDTypep, BasicDType) && portp->direction() != VDirection::REF
&& (VN_IS(portDTypep, UnpackArrayDType) || VN_IS(portDTypep, DynArrayDType)
|| VN_IS(portDTypep, QueueDType) || VN_IS(portDTypep, AssocArrayDType))) {
if (portp->direction() != VDirection::REF
&& !(portp->basicp()
&& portp->basicp()->untyped()) // for properties, handled in V3AssertPre
&& ((VN_IS(portDTypep, BasicDType) && pinDTypep->isNonPackedArray())
|| (VN_IS(pinDTypep, BasicDType) && portDTypep->isNonPackedArray()))) {
pinp->v3error("Function Argument expects " << portDTypep->prettyDTypeNameQ()
<< ", got "
<< pinDTypep->prettyDTypeNameQ());