Skip to content

Commit 9de0ed2

Browse files
committed
Fix a couple of variable shadowing warnings from a Sandia intel 17 build.
1 parent bad1a68 commit 9de0ed2

File tree

4 files changed

+9
-12
lines changed

4 files changed

+9
-12
lines changed

src/AssembleMomentumNonConformalSolverAlgorithm.C

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -511,10 +511,10 @@ AssembleMomentumNonConformalSolverAlgorithm::execute()
511511
for ( int j = 0; j < nDim; ++j ) {
512512
const double nxj = p_cNx[j];
513513
const double dndxj = p_c_dndx[offSetDnDx+j];
514-
for ( int i = 0; i < nDim; ++i ) {
515-
const double dndxi = p_c_dndx[offSetDnDx+i];
514+
for ( int kk = 0; kk < nDim; ++kk ) {
515+
const double dndxi = p_c_dndx[offSetDnDx+kk];
516516
// -mu*dui/dxj*Aj (divU neglected)
517-
p_lhs[rowR+icNdim+i] += -currentDiffFluxCoeffBip*dndxj*nxj*c_amag/2.0;
517+
p_lhs[rowR+icNdim+kk] += -currentDiffFluxCoeffBip*dndxj*nxj*c_amag/2.0;
518518
// -mu*duj/dxi*Aj
519519
p_lhs[rowR+icNdim+j] += -currentDiffFluxCoeffBip*dndxi*nxj*c_amag/2.0;
520520
}
@@ -536,10 +536,10 @@ AssembleMomentumNonConformalSolverAlgorithm::execute()
536536
for ( int j = 0; j < nDim; ++j ) {
537537
const double nxj = p_oNx[j];
538538
const double dndxj = p_o_dndx[offSetDnDx+j];
539-
for ( int i = 0; i < nDim; ++i ) {
540-
const double dndxi = p_o_dndx[offSetDnDx+i];
539+
for ( int kk = 0; kk < nDim; ++kk ) {
540+
const double dndxi = p_o_dndx[offSetDnDx+kk];
541541
// -mu*dui/dxj*Aj (divU neglected)
542-
p_lhs[rowR+icNdim+i] -= -currentDiffFluxCoeffBip*dndxj*nxj*c_amag/2.0;
542+
p_lhs[rowR+icNdim+kk] -= -currentDiffFluxCoeffBip*dndxj*nxj*c_amag/2.0;
543543
// -mu*duj/dxi*Aj
544544
p_lhs[rowR+icNdim+j] -= -currentDiffFluxCoeffBip*dndxi*nxj*c_amag/2.0;
545545
}

src/LowMachEquationSystem.C

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1718,11 +1718,10 @@ MomentumEquationSystem::register_wall_bc(
17181718
ConstantAuxFunction *theHeatFluxAuxFunc = new ConstantAuxFunction(0, 1, userSpec);
17191719

17201720
// bc data alg
1721-
AuxFunctionAlgorithm *auxAlg
1722-
= new AuxFunctionAlgorithm(realm_, part,
1721+
bcDataAlg_.push_back( new AuxFunctionAlgorithm(realm_, part,
17231722
theHeatFluxBcField, theHeatFluxAuxFunc,
1724-
stk::topology::NODE_RANK);
1725-
bcDataAlg_.push_back(auxAlg);
1723+
stk::topology::NODE_RANK)
1724+
);
17261725

17271726
const AlgorithmType wfAlgType = WALL_ABL;
17281727

src/nso/MomentumNSOElemSuppAlgDep.C

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -293,7 +293,6 @@ MomentumNSOElemSuppAlgDep::elem_execute(
293293
}
294294

295295
// determine scs values of interest
296-
const int offSet = ip*nodesPerElement;
297296
for ( int ic = 0; ic < nodesPerElement; ++ic ) {
298297

299298
const int icNdim = ic*nDim_;

src/nso/MomentumNSOGradElemSuppAlg.C

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -239,7 +239,6 @@ MomentumNSOGradElemSuppAlg::elem_execute(
239239
}
240240

241241
// determine scs values of interest
242-
const int offSet = ip*nodesPerElement;
243242
for ( int ic = 0; ic < nodesPerElement; ++ic ) {
244243

245244
const int icNdim = ic*nDim_;

0 commit comments

Comments
 (0)