Apply 'make format'

This commit is contained in:
github action 2026-06-06 00:44:02 +00:00
parent bc86701bec
commit e9274be247
2 changed files with 15 additions and 12 deletions

View File

@ -251,7 +251,6 @@ public:
return varRefp;
}
static AstNodeExpr* buildNestedArraySel(FileLine* flp, AstNodeExpr* fromp,
const std::vector<int>& indicies) {
AstNodeExpr* curp = fromp;
@ -407,8 +406,7 @@ public:
AstNodeStmt* createForceRdUpdateStmtUnpacked(const VarForceInfo& varInfo) const {
FileLine* const flp = varInfo.m_varVscp->fileline();
AstVar* const varp = varInfo.m_varVscp->varp();
AstUnpackArrayDType* const arrDtypep
= VN_AS(varp->dtypep()->skipRefp(), UnpackArrayDType);
AstUnpackArrayDType* const arrDtypep = VN_AS(varp->dtypep()->skipRefp(), UnpackArrayDType);
const std::vector<AstUnpackArrayDType*> dims = arrDtypep->unpackDimensions();
return foreachUnpackedLeaf(
dims, [&](const std::vector<int>& idx, int /*flat*/) -> AstNodeStmt* {
@ -633,8 +631,7 @@ public:
AstNodeStmt* initStmtp = nullptr;
if (AstUnpackArrayDType* const arrDtypep
= VN_CAST(varp->dtypeSkipRefp(), UnpackArrayDType)) {
const std::vector<AstUnpackArrayDType*> dims
= arrDtypep->unpackDimensions();
const std::vector<AstUnpackArrayDType*> dims = arrDtypep->unpackDimensions();
const int innerWidth = dims.back()->subDTypep()->skipRefp()->width();
initStmtp = foreachUnpackedLeaf(
dims, [&](const std::vector<int>& idx, int /*flat*/) -> AstNodeStmt* {

View File

@ -26,20 +26,26 @@ int main(int argc, char** argv) {
bool changed = true;
switch (topp->cyc) {
case 1:
en[0][1] = 0x3; val[0][1] = 0x3;
en_a[0][1] = 0x3; val_a[0][1] = 0x2;
en[0][1] = 0x3;
val[0][1] = 0x3;
en_a[0][1] = 0x3;
val_a[0][1] = 0x2;
break;
case 2:
en[1][0] = 0x3; val[1][0] = 0x2;
en_a[1][0] = 0x3; val_a[1][0] = 0x3;
en[1][0] = 0x3;
val[1][0] = 0x2;
en_a[1][0] = 0x3;
val_a[1][0] = 0x3;
break;
case 3:
en[0][1] = 0x0; en_a[0][1] = 0x0;
en[0][1] = 0x0;
en_a[0][1] = 0x0;
break;
case 4:
en[1][0] = 0x0; en_a[1][0] = 0x0;
en[1][0] = 0x0;
en_a[1][0] = 0x0;
break;
default: changed = false;
}
if (changed) topp->eval();