mirror of
https://github.com/verilator/verilator.git
synced 2026-10-07 10:33:13 +02:00
Internals: Add range Left/Right/Lo/Hi iterable sequences (#8585)
This commit is contained in:
+2
-2
@@ -461,7 +461,7 @@ class CoverageVisitor final : public VNVisitor {
|
||||
if (const AstBasicDType* const basicp = VN_CAST(dtypep, BasicDType)) {
|
||||
toggleVarBottom(above, varp, basicp->nrange());
|
||||
} else if (const AstUnpackArrayDType* const adtypep = VN_CAST(dtypep, UnpackArrayDType)) {
|
||||
for (int index_docs = adtypep->lo(); index_docs <= adtypep->hi(); ++index_docs) {
|
||||
for (const int index_docs : adtypep->declRange().seqLoToHi()) {
|
||||
const int index_code = index_docs - adtypep->lo();
|
||||
ToggleEnt newent{above.m_comment + "["s + cvtToStr(index_docs) + "]",
|
||||
new AstArraySel{varp->fileline(),
|
||||
@@ -472,7 +472,7 @@ class CoverageVisitor final : public VNVisitor {
|
||||
newent.cleanup();
|
||||
}
|
||||
} else if (const AstPackArrayDType* const adtypep = VN_CAST(dtypep, PackArrayDType)) {
|
||||
for (int index_docs = adtypep->lo(); index_docs <= adtypep->hi(); ++index_docs) {
|
||||
for (const int index_docs : adtypep->declRange().seqLoToHi()) {
|
||||
const AstNodeDType* const subtypep = adtypep->subDTypep()->skipRefp();
|
||||
const int index_code = index_docs - adtypep->lo();
|
||||
ToggleEnt newent{above.m_comment + "["s + cvtToStr(index_docs) + "]",
|
||||
|
||||
Reference in New Issue
Block a user