Skip to content

Commit fa0c190

Browse files
committed
Rename PC->Pc to avoid hiding typename (now mimics jac -> Jac)
1 parent 11be353 commit fa0c190

1 file changed

Lines changed: 11 additions & 11 deletions

File tree

src/solvers/petsc_nonlinear_solver.C

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -432,7 +432,7 @@ extern "C"
432432

433433
NonlinearImplicitSystem & sys = solver->system();
434434

435-
PetscMatrixBase<Number> * const PC = pc ? PetscMatrixBase<Number>::get_context(pc, sys.comm()) : nullptr;
435+
PetscMatrixBase<Number> * const Pc = pc ? PetscMatrixBase<Number>::get_context(pc, sys.comm()) : nullptr;
436436
PetscMatrixBase<Number> * Jac = jac ? PetscMatrixBase<Number>::get_context(jac, sys.comm()) : nullptr;
437437
PetscVector<Number> & X_sys = *cast_ptr<PetscVector<Number> *>(sys.solution.get());
438438
PetscVector<Number> X_global(x, sys.comm());
@@ -462,13 +462,13 @@ extern "C"
462462
Jac->close();
463463

464464
if (pc && (p_is_shell == PETSC_TRUE))
465-
PC->close();
465+
Pc->close();
466466

467467
PetscFunctionReturn(LIBMESH_PETSC_SUCCESS);
468468
}
469469

470470
// Set the dof maps
471-
PC->attach_dof_map(sys.get_dof_map());
471+
Pc->attach_dof_map(sys.get_dof_map());
472472
Jac->attach_dof_map(sys.get_dof_map());
473473

474474
// Use the systems update() to get a good local version of the parallel solution
@@ -484,29 +484,29 @@ extern "C"
484484
sys.get_dof_map().enforce_constraints_exactly(sys, sys.current_local_solution.get());
485485

486486
if (solver->_zero_out_jacobian)
487-
PC->zero();
487+
Pc->zero();
488488

489489

490490
if (solver->jacobian != nullptr)
491-
solver->jacobian(*sys.current_local_solution.get(), *PC, sys);
491+
solver->jacobian(*sys.current_local_solution.get(), *Pc, sys);
492492

493493
else if (solver->jacobian_object != nullptr)
494-
solver->jacobian_object->jacobian(*sys.current_local_solution.get(), *PC, sys);
494+
solver->jacobian_object->jacobian(*sys.current_local_solution.get(), *Pc, sys);
495495

496496
else if (solver->matvec != nullptr)
497-
solver->matvec(*sys.current_local_solution.get(), nullptr, PC, sys);
497+
solver->matvec(*sys.current_local_solution.get(), nullptr, Pc, sys);
498498

499499
else
500500
libmesh_error_msg("Error! Unable to compute residual and/or Jacobian!");
501501

502-
PC->close();
502+
Pc->close();
503503
if (solver->_exact_constraint_enforcement)
504504
{
505-
sys.get_dof_map().enforce_constraints_on_jacobian(sys, PC);
506-
PC->close();
505+
sys.get_dof_map().enforce_constraints_on_jacobian(sys, Pc);
506+
Pc->close();
507507
}
508508

509-
if (Jac != PC)
509+
if (Jac != Pc)
510510
{
511511
// Assume that shells know what they're doing
512512
libmesh_assert(!solver->_exact_constraint_enforcement || (j_is_mffd == PETSC_TRUE) ||

0 commit comments

Comments
 (0)