From c972c254d63565fc011f854621914c428e3b46db Mon Sep 17 00:00:00 2001 From: Daniel Arndt Date: Fri, 7 Apr 2017 11:30:47 +0200 Subject: [PATCH] Fix double brackets --- include/deal.II/base/array_view.h | 2 +- include/deal.II/base/index_set.h | 4 ++-- include/deal.II/base/memory_consumption.h | 2 +- include/deal.II/base/parameter_handler.h | 2 +- include/deal.II/base/thread_management.h | 2 +- include/deal.II/base/time_stepping.templates.h | 10 +++++----- include/deal.II/dofs/dof_accessor.templates.h | 2 +- include/deal.II/fe/fe_enriched.h | 2 +- include/deal.II/grid/tria.h | 2 +- include/deal.II/grid/tria_accessor.h | 2 +- include/deal.II/grid/tria_accessor.templates.h | 4 ++-- .../deal.II/lac/la_parallel_vector.templates.h | 4 ++-- include/deal.II/lac/petsc_compatibility.h | 6 +++--- include/deal.II/lac/precondition.h | 4 ++-- include/deal.II/lac/read_write_vector.h | 8 ++++---- .../deal.II/lac/read_write_vector.templates.h | 12 ++++++------ include/deal.II/lac/relaxation_block.h | 2 +- include/deal.II/lac/solver_bicgstab.h | 18 +++++++++--------- include/deal.II/lac/solver_cg.h | 12 ++++++------ include/deal.II/lac/solver_minres.h | 14 +++++++------- include/deal.II/lac/solver_richardson.h | 8 ++++---- .../deal.II/matrix_free/dof_info.templates.h | 2 +- include/deal.II/matrix_free/matrix_free.h | 6 +++--- include/deal.II/matrix_free/operators.h | 11 ++++++----- include/deal.II/meshworker/integration_info.h | 2 +- include/deal.II/meshworker/simple.h | 2 +- include/deal.II/multigrid/mg_coarse.h | 4 ++-- .../numerics/matrix_creator.templates.h | 4 ++-- source/base/parameter_handler.cc | 12 ++++++------ source/fe/fe_enriched.cc | 2 +- source/fe/fe_tools_extrapolate.cc | 12 ++++++------ 31 files changed, 90 insertions(+), 89 deletions(-) diff --git a/include/deal.II/base/array_view.h b/include/deal.II/base/array_view.h index a9f0788161..e629a12213 100644 --- a/include/deal.II/base/array_view.h +++ b/include/deal.II/base/array_view.h @@ -157,7 +157,7 @@ template inline ArrayView::ArrayView() : - starting_element ((nullptr)), + starting_element (nullptr), n_elements(0) {} diff --git a/include/deal.II/base/index_set.h b/include/deal.II/base/index_set.h index 57492087ef..6a5e153197 100644 --- a/include/deal.II/base/index_set.h +++ b/include/deal.II/base/index_set.h @@ -917,7 +917,7 @@ IndexSet::size_type IndexSet::IntervalAccessor::n_elements() const inline bool IndexSet::IntervalAccessor::is_valid() const { - return index_set !=nullptr&& range_idx < index_set->n_intervals(); + return index_set != nullptr && range_idx < index_set->n_intervals(); } inline @@ -999,7 +999,7 @@ IndexSet::IntervalIterator::IntervalIterator(const IndexSet *idxset, const Index inline IndexSet::IntervalIterator::IntervalIterator() - : accessor((nullptr)) + : accessor(nullptr) {} inline diff --git a/include/deal.II/base/memory_consumption.h b/include/deal.II/base/memory_consumption.h index af99222dd5..94d3ee412c 100644 --- a/include/deal.II/base/memory_consumption.h +++ b/include/deal.II/base/memory_consumption.h @@ -280,7 +280,7 @@ namespace MemoryConsumption inline std::size_t memory_consumption (const char *string) { - if (string == (nullptr)) + if (string == nullptr) { return 0; } diff --git a/include/deal.II/base/parameter_handler.h b/include/deal.II/base/parameter_handler.h index 489ed9cee3..80230f5101 100644 --- a/include/deal.II/base/parameter_handler.h +++ b/include/deal.II/base/parameter_handler.h @@ -288,7 +288,7 @@ namespace Patterns /** * Creates a new object on the heap using @p new if the given * @p description is a valid format (for example created by calling - * description() on an existing object), or nullptr otherwise. Ownership + * description() on an existing object), or @p nullptr otherwise. Ownership * of the returned object is transferred to the caller of this function, * which should be freed using @p delete. */ diff --git a/include/deal.II/base/thread_management.h b/include/deal.II/base/thread_management.h index 9387292954..a1c48bc546 100644 --- a/include/deal.II/base/thread_management.h +++ b/include/deal.II/base/thread_management.h @@ -2900,7 +2900,7 @@ namespace Threads TaskDescriptor::TaskDescriptor (const std::function &function) : function (function), - task((nullptr)), + task(nullptr), task_is_done (false) {} diff --git a/include/deal.II/base/time_stepping.templates.h b/include/deal.II/base/time_stepping.templates.h index f7342a1a0e..1c89157093 100644 --- a/include/deal.II/base/time_stepping.templates.h +++ b/include/deal.II/base/time_stepping.templates.h @@ -415,7 +415,7 @@ namespace TimeStepping refine_tol(refine_tol), coarsen_tol(coarsen_tol), last_same_as_first(false), - last_stage((nullptr)) + last_stage(nullptr) { initialize(method); } @@ -665,10 +665,10 @@ namespace TimeStepping template void EmbeddedExplicitRungeKutta::free_memory() { - if (last_stage!=(nullptr)) + if (last_stage!=nullptr) delete last_stage; - last_stage = (nullptr); + last_stage = nullptr; } @@ -762,7 +762,7 @@ namespace TimeStepping // Save the last stage if necessary if (last_same_as_first==true) { - if (last_stage==(nullptr)) + if (last_stage==nullptr) last_stage = new VectorType(f_stages.back()); else *last_stage = f_stages.back(); @@ -817,7 +817,7 @@ namespace TimeStepping // of the first stage. if (last_same_as_first==true) { - if (last_stage!=(nullptr)) + if (last_stage!=nullptr) { f_stages[0] = *last_stage; i = 1; diff --git a/include/deal.II/dofs/dof_accessor.templates.h b/include/deal.II/dofs/dof_accessor.templates.h index a3e5fc0ab4..7c45c37a3c 100644 --- a/include/deal.II/dofs/dof_accessor.templates.h +++ b/include/deal.II/dofs/dof_accessor.templates.h @@ -60,7 +60,7 @@ DoFAccessor (const Triangulation(dof_handler)) { - Assert (tria ==nullptr|| &dof_handler->get_triangulation() == tria, + Assert (tria == nullptr || &dof_handler->get_triangulation() == tria, ExcMessage ("You can't create a DoF accessor in which the DoFHandler object " "uses a different triangulation than the one you pass as argument.")); } diff --git a/include/deal.II/fe/fe_enriched.h b/include/deal.II/fe/fe_enriched.h index 8f2de8c5d8..097da0edb7 100644 --- a/include/deal.II/fe/fe_enriched.h +++ b/include/deal.II/fe/fe_enriched.h @@ -136,7 +136,7 @@ DEAL_II_NAMESPACE_OPEN * @code * FE_Enriched fe_non_enriched(FE_Q(1), * FE_Nothing(1,true), - * (nullptr)); + * nullptr); * @endcode * and will result in the correct constraints for enriched DoFs attributed to * support points on the interface between the two regions. diff --git a/include/deal.II/grid/tria.h b/include/deal.II/grid/tria.h index 56b9f2aba6..f6326892cb 100644 --- a/include/deal.II/grid/tria.h +++ b/include/deal.II/grid/tria.h @@ -930,7 +930,7 @@ namespace internal * classes. Again, see * @ref GlossUserData "the glossary for more information". * - * The value of these user indices or pointers is @pnullptrby default. Note + * The value of these user indices or pointers is @p nullptr by default. Note * that the pointers are not inherited to children upon refinement. Still, * after a remeshing they are available on all cells, where they were set on * the previous mesh. diff --git a/include/deal.II/grid/tria_accessor.h b/include/deal.II/grid/tria_accessor.h index 0c105a5c62..37798404f6 100644 --- a/include/deal.II/grid/tria_accessor.h +++ b/include/deal.II/grid/tria_accessor.h @@ -1104,7 +1104,7 @@ public: void set_user_pointer (void *p) const; /** - * Reset the user pointer to a @pnullptrpointer. See + * Reset the user pointer to a @p nullptr pointer. See * @ref GlossUserData * for more information. */ diff --git a/include/deal.II/grid/tria_accessor.templates.h b/include/deal.II/grid/tria_accessor.templates.h index 3380734e66..18c532198a 100644 --- a/include/deal.II/grid/tria_accessor.templates.h +++ b/include/deal.II/grid/tria_accessor.templates.h @@ -2134,7 +2134,7 @@ inline TriaAccessor<0, dim, spacedim>:: TriaAccessor (const TriaAccessor &) : - tria ((nullptr)), + tria (nullptr), global_vertex_index (numbers::invalid_unsigned_int) { Assert(false, ExcImpossibleInDim(0)); @@ -2148,7 +2148,7 @@ inline TriaAccessor<0, dim, spacedim>:: TriaAccessor (const InvalidAccessor &) : - tria ((nullptr)), + tria (nullptr), global_vertex_index (numbers::invalid_unsigned_int) { Assert(false, ExcImpossibleInDim(0)); diff --git a/include/deal.II/lac/la_parallel_vector.templates.h b/include/deal.II/lac/la_parallel_vector.templates.h index d23101c5b4..b886ca1658 100644 --- a/include/deal.II/lac/la_parallel_vector.templates.h +++ b/include/deal.II/lac/la_parallel_vector.templates.h @@ -831,7 +831,7 @@ namespace LinearAlgebra // If no communication pattern is given, create one. Otherwise, use the // given one. std::shared_ptr comm_pattern; - if (communication_pattern.get() == (nullptr)) + if (communication_pattern.get() == nullptr) { // Split the IndexSet of V in locally owned elements and ghost indices // then create the communication pattern @@ -1552,7 +1552,7 @@ namespace LinearAlgebra const bool scientific, const bool across) const { - Assert (partitioner.get() !=nullptr, ExcInternalError()); + Assert (partitioner.get() != nullptr, ExcInternalError()); AssertThrow (out, ExcIO()); std::ios::fmtflags old_flags = out.flags(); unsigned int old_precision = out.precision (precision); diff --git a/include/deal.II/lac/petsc_compatibility.h b/include/deal.II/lac/petsc_compatibility.h index b3bb1309a5..abcbbdf657 100644 --- a/include/deal.II/lac/petsc_compatibility.h +++ b/include/deal.II/lac/petsc_compatibility.h @@ -53,7 +53,7 @@ namespace PETScWrappers #if DEAL_II_PETSC_VERSION_LT(3, 7, 0) const PetscErrorCode ierr = PetscOptionsSetValue (name.c_str (), value.c_str ()); #else - const PetscErrorCode ierr = PetscOptionsSetValue ((nullptr), name.c_str (), value.c_str ()); + const PetscErrorCode ierr = PetscOptionsSetValue (nullptr, name.c_str (), value.c_str ()); #endif AssertThrow (ierr == 0, ExcPETScError(ierr)); } @@ -72,7 +72,7 @@ namespace PETScWrappers */ inline PetscErrorCode destroy_matrix (Mat &matrix) { - // PETSc will check whether or not matrix is (nullptr). + // PETSc will check whether or not matrix is nullptr. #if DEAL_II_PETSC_VERSION_LT(3, 2, 0) return MatDestroy (matrix); #else @@ -94,7 +94,7 @@ namespace PETScWrappers */ inline PetscErrorCode destroy_krylov_solver (KSP &krylov_solver) { - // PETSc will check whether or not matrix is (nullptr). + // PETSc will check whether or not matrix is nullptr. #if DEAL_II_PETSC_VERSION_LT(3, 2, 0) return KSPDestroy (krylov_solver); #else diff --git a/include/deal.II/lac/precondition.h b/include/deal.II/lac/precondition.h index b11311965e..3d92b78eff 100644 --- a/include/deal.II/lac/precondition.h +++ b/include/deal.II/lac/precondition.h @@ -1912,10 +1912,10 @@ namespace internal std::shared_ptr > &preconditioner, VectorType &diagonal_inverse) { - if (preconditioner.get() ==nullptr|| + if (preconditioner.get() == nullptr || preconditioner->m() != matrix.m()) { - if (preconditioner.get() == (nullptr)) + if (preconditioner.get() == nullptr) preconditioner.reset(new DiagonalMatrix()); Assert(preconditioner->m() == 0, diff --git a/include/deal.II/lac/read_write_vector.h b/include/deal.II/lac/read_write_vector.h index 9a28632cf8..2f38a41ea4 100644 --- a/include/deal.II/lac/read_write_vector.h +++ b/include/deal.II/lac/read_write_vector.h @@ -624,7 +624,7 @@ namespace LinearAlgebra inline ReadWriteVector::ReadWriteVector () : - val((nullptr)) + val(nullptr) { reinit(0, true); } @@ -636,7 +636,7 @@ namespace LinearAlgebra ReadWriteVector::ReadWriteVector (const ReadWriteVector &v) : Subscriptor(), - val((nullptr)) + val(nullptr) { this->operator=(v); } @@ -647,7 +647,7 @@ namespace LinearAlgebra inline ReadWriteVector::ReadWriteVector (const size_type size) : - val((nullptr)) + val(nullptr) { reinit (size, false); } @@ -658,7 +658,7 @@ namespace LinearAlgebra inline ReadWriteVector::ReadWriteVector (const IndexSet &locally_stored_indices) : - val((nullptr)) + val(nullptr) { reinit (locally_stored_indices); } diff --git a/include/deal.II/lac/read_write_vector.templates.h b/include/deal.II/lac/read_write_vector.templates.h index 0436e49d87..fd25e4b344 100644 --- a/include/deal.II/lac/read_write_vector.templates.h +++ b/include/deal.II/lac/read_write_vector.templates.h @@ -52,14 +52,14 @@ namespace LinearAlgebra { if (new_alloc_size == 0) { - if (val != (nullptr)) + if (val != nullptr) free(val); - val = (nullptr); + val = nullptr; thread_loop_partitioner.reset(new parallel::internal::TBBPartitioner()); } else { - if (val != (nullptr)) + if (val != nullptr) free(val); Utilities::System::posix_memalign ((void **)&val, 64, sizeof(Number)*new_alloc_size); @@ -206,7 +206,7 @@ namespace LinearAlgebra // If no communication pattern is given, create one. Otherwise, use the // given one. std::shared_ptr comm_pattern; - if (communication_pattern.get() == (nullptr)) + if (communication_pattern.get() == nullptr) { comm_pattern.reset(new Utilities::MPI::Partitioner(vec.locally_owned_elements(), get_stored_elements(), @@ -305,7 +305,7 @@ namespace LinearAlgebra // If no communication pattern is given, create one. Otherwise, use the one // given. - if (communication_pattern == (nullptr)) + if (communication_pattern == nullptr) { // The first time import is called, we create a communication pattern. // Check if the communication pattern already exists and if it can be @@ -315,7 +315,7 @@ namespace LinearAlgebra { epetra_comm_pattern = std::dynamic_pointer_cast (comm_pattern); - if (epetra_comm_pattern == (nullptr)) + if (epetra_comm_pattern == nullptr) epetra_comm_pattern = std::make_shared( create_epetra_comm_pattern(source_elements, mpi_comm)); } diff --git a/include/deal.II/lac/relaxation_block.h b/include/deal.II/lac/relaxation_block.h index cb1aebfeb6..ad6b0dc641 100644 --- a/include/deal.II/lac/relaxation_block.h +++ b/include/deal.II/lac/relaxation_block.h @@ -91,7 +91,7 @@ public: const typename PreconditionBlockBase::Inversion inversion = PreconditionBlockBase::gauss_jordan, const double threshold = 0., - VectorType *temp_ghost_vector = (nullptr)); + VectorType *temp_ghost_vector = nullptr); /** * The mapping from indices to blocks. Each row of this pattern enumerates diff --git a/include/deal.II/lac/solver_bicgstab.h b/include/deal.II/lac/solver_bicgstab.h index 2745f93ffd..df2d5ca800 100644 --- a/include/deal.II/lac/solver_bicgstab.h +++ b/include/deal.II/lac/solver_bicgstab.h @@ -296,15 +296,15 @@ SolverBicgstab::SolverBicgstab (SolverControl &cn, const AdditionalData &data) : Solver(cn), - Vx((nullptr)), - Vr((nullptr)), - Vrbar((nullptr)), - Vp((nullptr)), - Vy((nullptr)), - Vz((nullptr)), - Vt((nullptr)), - Vv((nullptr)), - Vb((nullptr)), + Vx(nullptr), + Vr(nullptr), + Vrbar(nullptr), + Vp(nullptr), + Vy(nullptr), + Vz(nullptr), + Vt(nullptr), + Vv(nullptr), + Vb(nullptr), alpha(0.), beta(0.), omega(0.), diff --git a/include/deal.II/lac/solver_cg.h b/include/deal.II/lac/solver_cg.h index 9faae8f510..53fcf63bdf 100644 --- a/include/deal.II/lac/solver_cg.h +++ b/include/deal.II/lac/solver_cg.h @@ -327,9 +327,9 @@ SolverCG::SolverCG (SolverControl &cn, const AdditionalData &data) : Solver(cn,mem), - Vr((nullptr)), - Vp((nullptr)), - Vz((nullptr)), + Vr(nullptr), + Vp(nullptr), + Vz(nullptr), additional_data(data) {} @@ -340,9 +340,9 @@ SolverCG::SolverCG (SolverControl &cn, const AdditionalData &data) : Solver(cn), - Vr((nullptr)), - Vp((nullptr)), - Vz((nullptr)), + Vr(nullptr), + Vp(nullptr), + Vz(nullptr), additional_data(data) {} diff --git a/include/deal.II/lac/solver_minres.h b/include/deal.II/lac/solver_minres.h index 0cde0917e7..72f407422a 100644 --- a/include/deal.II/lac/solver_minres.h +++ b/include/deal.II/lac/solver_minres.h @@ -169,13 +169,13 @@ SolverMinRes::SolverMinRes (SolverControl &cn, const AdditionalData &) : Solver(cn), - Vu0((nullptr)), - Vu1((nullptr)), - Vu2((nullptr)), - Vm0((nullptr)), - Vm1((nullptr)), - Vm2((nullptr)), - Vv((nullptr)), + Vu0(nullptr), + Vu1(nullptr), + Vu2(nullptr), + Vm0(nullptr), + Vm1(nullptr), + Vm2(nullptr), + Vv(nullptr), res2(numbers::signaling_nan()) {} diff --git a/include/deal.II/lac/solver_richardson.h b/include/deal.II/lac/solver_richardson.h index bdfe70b3f4..f387cfcbbd 100644 --- a/include/deal.II/lac/solver_richardson.h +++ b/include/deal.II/lac/solver_richardson.h @@ -194,8 +194,8 @@ SolverRichardson::SolverRichardson(SolverControl &cn, const AdditionalData &data) : Solver (cn,mem), - Vr((nullptr)), - Vd((nullptr)), + Vr(nullptr), + Vd(nullptr), additional_data(data) {} @@ -206,8 +206,8 @@ SolverRichardson::SolverRichardson(SolverControl &cn, const AdditionalData &data) : Solver (cn), - Vr((nullptr)), - Vd((nullptr)), + Vr(nullptr), + Vd(nullptr), additional_data(data), res(numbers::signaling_nan()) {} diff --git a/include/deal.II/matrix_free/dof_info.templates.h b/include/deal.II/matrix_free/dof_info.templates.h index 7c49f391a9..f1d7f473bb 100644 --- a/include/deal.II/matrix_free/dof_info.templates.h +++ b/include/deal.II/matrix_free/dof_info.templates.h @@ -182,7 +182,7 @@ namespace internal ConstraintValues &constraint_values, bool &cell_at_boundary) { - Assert (vector_partitioner.get() !=nullptr, ExcInternalError()); + Assert (vector_partitioner.get() != nullptr, ExcInternalError()); const unsigned int n_mpi_procs = vector_partitioner->n_mpi_processes(); const types::global_dof_index first_owned = vector_partitioner->local_range().first; const types::global_dof_index last_owned = vector_partitioner->local_range().second; diff --git a/include/deal.II/matrix_free/matrix_free.h b/include/deal.II/matrix_free/matrix_free.h index 65b46baa12..e770c02af4 100644 --- a/include/deal.II/matrix_free/matrix_free.h +++ b/include/deal.II/matrix_free/matrix_free.h @@ -2100,7 +2100,7 @@ namespace internal const internal::MatrixFreeFunctions::TaskInfo &task_info_in, const bool is_blocked_in) : - dummy ((nullptr)), + dummy (nullptr), worker (worker_in), partition (partition_in), task_info (task_info_in), @@ -2137,7 +2137,7 @@ namespace internal const internal::MatrixFreeFunctions::TaskInfo &task_info_in, const bool is_blocked_in = false) : - dummy ((nullptr)), + dummy (nullptr), function (function_in), partition (partition_in), task_info (task_info_in), @@ -2265,7 +2265,7 @@ namespace internal const internal::MatrixFreeFunctions::TaskInfo &task_info_in, const bool is_blocked_in) : - dummy ((nullptr)), + dummy (nullptr), worker (worker_in), partition (partition_in), task_info (task_info_in), diff --git a/include/deal.II/matrix_free/operators.h b/include/deal.II/matrix_free/operators.h index 22ac681c59..2717bee872 100644 --- a/include/deal.II/matrix_free/operators.h +++ b/include/deal.II/matrix_free/operators.h @@ -931,7 +931,7 @@ namespace MatrixFreeOperators { (void) col; Assert (row == col, ExcNotImplemented()); - Assert (inverse_diagonal_entries.get() !=nullptr&& + Assert (inverse_diagonal_entries.get() != nullptr && inverse_diagonal_entries->m() > 0, ExcNotInitialized()); return 1.0/(*inverse_diagonal_entries)(row,row); } @@ -1344,7 +1344,8 @@ namespace MatrixFreeOperators std::size_t Base::memory_consumption () const { - return inverse_diagonal_entries.get() !=nullptr? inverse_diagonal_entries->memory_consumption() : sizeof(*this); + return inverse_diagonal_entries.get() != nullptr ? + inverse_diagonal_entries->memory_consumption() : sizeof(*this); } @@ -1362,7 +1363,7 @@ namespace MatrixFreeOperators const std::shared_ptr > & Base::get_matrix_diagonal_inverse() const { - Assert(inverse_diagonal_entries.get() !=nullptr&& + Assert(inverse_diagonal_entries.get() != nullptr && inverse_diagonal_entries->m() > 0, ExcNotInitialized()); return inverse_diagonal_entries; } @@ -1399,7 +1400,7 @@ namespace MatrixFreeOperators MGInterfaceOperator::MGInterfaceOperator () : Subscriptor(), - mf_base_operator((nullptr)) + mf_base_operator(nullptr) { } @@ -1409,7 +1410,7 @@ namespace MatrixFreeOperators void MGInterfaceOperator::clear () { - mf_base_operator = (nullptr); + mf_base_operator = nullptr; } diff --git a/include/deal.II/meshworker/integration_info.h b/include/deal.II/meshworker/integration_info.h index 5bbb513d2b..c494c1174c 100644 --- a/include/deal.II/meshworker/integration_info.h +++ b/include/deal.II/meshworker/integration_info.h @@ -633,7 +633,7 @@ namespace MeshWorker inline const FiniteElement & IntegrationInfo::finite_element() const { - Assert (fe_pointer !=nullptr, ExcNotInitialized()); + Assert (fe_pointer != nullptr, ExcNotInitialized()); return *fe_pointer; } diff --git a/include/deal.II/meshworker/simple.h b/include/deal.II/meshworker/simple.h index 4e09dc91be..0dba648c89 100644 --- a/include/deal.II/meshworker/simple.h +++ b/include/deal.II/meshworker/simple.h @@ -524,7 +524,7 @@ namespace MeshWorker info.indices: info.indices_by_block[i]; - if (constraints !=nullptr) + if (constraints != nullptr) constraints->distribute_local_to_global(info.vector(k).block(i), ldi, *v); else v->add(ldi, info.vector(k).block(i)); diff --git a/include/deal.II/multigrid/mg_coarse.h b/include/deal.II/multigrid/mg_coarse.h index 14680ac30d..0fa4ed6555 100644 --- a/include/deal.II/multigrid/mg_coarse.h +++ b/include/deal.II/multigrid/mg_coarse.h @@ -308,13 +308,13 @@ private: /* ------------------ Functions for MGCoarseGridApplySmoother -----------*/ template MGCoarseGridApplySmoother::MGCoarseGridApplySmoother () - : coarse_smooth((nullptr)) + : coarse_smooth(nullptr) { } template MGCoarseGridApplySmoother::MGCoarseGridApplySmoother (const MGSmootherBase &coarse_smooth) - : coarse_smooth((nullptr)) + : coarse_smooth(nullptr) { initialize(coarse_smooth); } diff --git a/include/deal.II/numerics/matrix_creator.templates.h b/include/deal.II/numerics/matrix_creator.templates.h index 1d85dcbe3c..a7aa61c31d 100644 --- a/include/deal.II/numerics/matrix_creator.templates.h +++ b/include/deal.II/numerics/matrix_creator.templates.h @@ -1220,7 +1220,7 @@ namespace MatrixCreator Assert (boundary_functions.size() != 0, ExcInternalError()); Assert (dof_to_boundary_mapping.size() == dof.n_dofs(), ExcInternalError()); - Assert (coefficient ==nullptr || + Assert (coefficient == nullptr || coefficient->n_components==1 || coefficient->n_components==n_components, ExcComponentMismatch()); @@ -1637,7 +1637,7 @@ namespace MatrixCreator Assert (boundary_functions.size() != 0, ExcInternalError()); Assert (dof_to_boundary_mapping.size() == dof.n_dofs(), ExcInternalError()); - Assert (coefficient ==nullptr || + Assert (coefficient == nullptr || coefficient->n_components==1 || coefficient->n_components==n_components, ExcComponentMismatch()); diff --git a/source/base/parameter_handler.cc b/source/base/parameter_handler.cc index a197206a23..a688c1d0c1 100644 --- a/source/base/parameter_handler.cc +++ b/source/base/parameter_handler.cc @@ -83,19 +83,19 @@ namespace Patterns return p; p = Double::create(description); - if (p !=nullptr ) + if (p != nullptr ) return p; p = Selection::create(description); - if (p !=nullptr ) + if (p != nullptr ) return p; p = List::create(description); - if (p !=nullptr ) + if (p != nullptr ) return p; p = MultipleSelection::create(description); - if (p !=nullptr ) + if (p != nullptr ) return p; p = Bool::create(description); @@ -103,11 +103,11 @@ namespace Patterns return p; p = Anything::create(description); - if (p !=nullptr ) + if (p != nullptr ) return p; p = FileName::create(description); - if (p !=nullptr ) + if (p != nullptr ) return p; p = DirectoryName::create(description); diff --git a/source/fe/fe_enriched.cc b/source/fe/fe_enriched.cc index 2fea36bcab..2b84fd8641 100644 --- a/source/fe/fe_enriched.cc +++ b/source/fe/fe_enriched.cc @@ -656,7 +656,7 @@ FE_Enriched::multiply_by_enrichment fe_data.enrichment[base_no].size())); for (unsigned int m=0; m < base_no_mult_local_enriched_dofs[base_no].size(); m++) { - Assert (enrichments[base_no-1][m](cell) !=nullptr, + Assert (enrichments[base_no-1][m](cell) != nullptr, ExcMessage("The pointer to the enrichment function is NULL")); Assert (enrichments[base_no-1][m](cell)->n_components == 1, diff --git a/source/fe/fe_tools_extrapolate.cc b/source/fe/fe_tools_extrapolate.cc index 5c8d76ba01..fa654fd043 100644 --- a/source/fe/fe_tools_extrapolate.cc +++ b/source/fe/fe_tools_extrapolate.cc @@ -1411,7 +1411,7 @@ namespace FETools { const parallel::distributed::Triangulation *parallel_tria = dynamic_cast*>(&dh.get_tria()); - Assert (parallel_tria !=nullptr, ExcNotImplemented()); + Assert (parallel_tria != nullptr, ExcNotImplemented()); const IndexSet locally_owned_dofs = dh.locally_owned_dofs(); vector.reinit(locally_owned_dofs, parallel_tria->get_communicator()); @@ -1425,7 +1425,7 @@ namespace FETools { const parallel::distributed::Triangulation *parallel_tria = dynamic_cast*>(&dh.get_tria()); - Assert (parallel_tria !=nullptr, ExcNotImplemented()); + Assert (parallel_tria != nullptr, ExcNotImplemented()); const IndexSet locally_owned_dofs = dh.locally_owned_dofs(); vector.reinit(locally_owned_dofs, parallel_tria->get_communicator()); @@ -1438,7 +1438,7 @@ namespace FETools { const parallel::distributed::Triangulation *parallel_tria = dynamic_cast*>(&dh.get_tria()); - Assert (parallel_tria !=nullptr, ExcNotImplemented()); + Assert (parallel_tria != nullptr, ExcNotImplemented()); const IndexSet locally_owned_dofs = dh.locally_owned_dofs(); vector.reinit(locally_owned_dofs, parallel_tria->get_communicator()); @@ -1460,7 +1460,7 @@ namespace FETools { const parallel::distributed::Triangulation *parallel_tria = dynamic_cast*>(&dh.get_tria()); - Assert(parallel_tria !=nullptr, ExcNotImplemented()); + Assert(parallel_tria != nullptr, ExcNotImplemented()); const IndexSet locally_owned_dofs = dh.locally_owned_dofs(); IndexSet locally_relevant_dofs; DoFTools::extract_locally_relevant_dofs (dh, locally_relevant_dofs); @@ -1476,7 +1476,7 @@ namespace FETools { const parallel::distributed::Triangulation *parallel_tria = dynamic_cast*>(&dh.get_tria()); - Assert (parallel_tria !=nullptr, ExcNotImplemented()); + Assert (parallel_tria != nullptr, ExcNotImplemented()); const IndexSet locally_owned_dofs = dh.locally_owned_dofs(); IndexSet locally_relevant_dofs; DoFTools::extract_locally_relevant_dofs (dh, locally_relevant_dofs); @@ -1491,7 +1491,7 @@ namespace FETools { const parallel::distributed::Triangulation *parallel_tria = dynamic_cast*>(&dh.get_tria()); - Assert (parallel_tria !=nullptr, ExcNotImplemented()); + Assert (parallel_tria != nullptr, ExcNotImplemented()); const IndexSet locally_owned_dofs = dh.locally_owned_dofs(); IndexSet locally_relevant_dofs; DoFTools::extract_locally_relevant_dofs (dh, locally_relevant_dofs); -- 2.39.5