Slicing: Fix off-by-one error earlier this version.
This commit is contained in:
parent
f6a745a4c2
commit
4b7ee8267b
|
|
@ -163,7 +163,7 @@ class SliceVisitor : public AstNVisitor {
|
|||
UINFO(9, " Bi-Eq/Neq expansion "<<nodep<<endl);
|
||||
if (AstUnpackArrayDType* adtypep = fromDtp->castUnpackArrayDType()) {
|
||||
AstNodeBiop* logp = NULL;
|
||||
for (int index = 0; index <= adtypep->rangep()->elementsConst(); ++index) {
|
||||
for (int index = 0; index < adtypep->rangep()->elementsConst(); ++index) {
|
||||
// EQ(a,b) -> LOGAND(EQ(ARRAYSEL(a,0), ARRAYSEL(b,0)), ...[1])
|
||||
AstNodeBiop* clonep = nodep->cloneType
|
||||
(new AstArraySel(nodep->fileline(),
|
||||
|
|
|
|||
Loading…
Reference in New Issue