Skip to content

Commit

Permalink
Per #1283, ci-skip-all, no real code changes. Just whitespace tweaks …
Browse files Browse the repository at this point in the history
…for internal consistency.
  • Loading branch information
JohnHalleyGotway committed Jun 16, 2023
1 parent ccfcdfc commit 0e05d4f
Show file tree
Hide file tree
Showing 2 changed files with 34 additions and 24 deletions.
1 change: 1 addition & 0 deletions src/basic/vx_util/data_plane.cc
Original file line number Diff line number Diff line change
Expand Up @@ -400,6 +400,7 @@ void DataPlane::set_accum(int s) {
}

///////////////////////////////////////////////////////////////////////////////

void DataPlane::set_all(float *data, int nx, int ny) {
if (nx != Nx || ny != Ny) {
mlog << Error << "\nDataPlane::set_all() -> "
Expand Down
57 changes: 33 additions & 24 deletions src/libcode/vx_bool_calc/bool_calc.cc
Original file line number Diff line number Diff line change
Expand Up @@ -127,41 +127,46 @@ return;

}


////////////////////////////////////////////////////////////////////////


bool BoolCalc::check_args(int expectedNargs) const

{
Program & P = *program;
Token tok;
vector<int> args;
bool status = true;

Program & P = *program;
Token tok;
vector<int> args;
bool status = true;

for (size_t j=0; j<P.size(); ++j) {
tok = P[j];
if (tok.type == tok_local_var) {
for (size_t j=0; j<P.size(); ++j) {
tok = P[j];
if (tok.type == tok_local_var) {
int index = tok.number_1b - 1;
if (find(args.begin(), args.end(), index) == args.end()) {
args.push_back(index);
args.push_back(index);
}
}
}
if ((int)args.size() != expectedNargs) {
mlog << Error << "\nBoolCalc::check_args() -> "
<< "expect " << expectedNargs << " args, got " << args.size() << "\n\n";
status = false;
}
for (size_t j=0; j<args.size(); ++j) {
if (args[j] < 0 || args[j] >= expectedNargs) {
}
}
if ((int)args.size() != expectedNargs) {
mlog << Error << "\nBoolCalc::check_args() -> "
<< "expect " << expectedNargs << " args, got " << args.size() << "\n\n";
status = false;
}
for (size_t j=0; j<args.size(); ++j) {
if (args[j] < 0 || args[j] >= expectedNargs) {
mlog << Error << "\nBoolCalc::check_args() -> "
<< "arg out of range " << args[j] << " range is 1 to " << expectedNargs << "\n\n";
<< "arg out of range " << args[j] << " range is 1 to " << expectedNargs << "\n\n";
status = false;
}
}
if (!status) {
dump_program(cerr);
}
return status;
}
}
if (!status) {
dump_program(cerr);
}

return status;

}

////////////////////////////////////////////////////////////////////////
Expand Down Expand Up @@ -249,7 +254,9 @@ return ( result );

////////////////////////////////////////////////////////////////////////


bool BoolCalc::has_union() const

{

Program & P = *program;
Expand All @@ -262,9 +269,11 @@ for (int j=0; j<((int) P.size()); ++j) {
return true;
}
}

return false;

}


////////////////////////////////////////////////////////////////////////

0 comments on commit 0e05d4f

Please sign in to comment.