From bf90f581635d06da58e80339188119539d502d6d Mon Sep 17 00:00:00 2001 From: Marc Fehling Date: Wed, 10 Jul 2019 17:01:25 +0200 Subject: [PATCH] No more anonymous namespace in p::d::CellDataTransfer. --- .../cell_data_transfer.templates.h | 41 ++++++++++++------- source/hp/dof_handler.cc | 23 ++++++----- 2 files changed, 38 insertions(+), 26 deletions(-) diff --git a/include/deal.II/distributed/cell_data_transfer.templates.h b/include/deal.II/distributed/cell_data_transfer.templates.h index 08523d833b..ed4e233e0c 100644 --- a/include/deal.II/distributed/cell_data_transfer.templates.h +++ b/include/deal.II/distributed/cell_data_transfer.templates.h @@ -37,23 +37,33 @@ DEAL_II_NAMESPACE_OPEN -namespace +namespace internal { - template - void - post_refinement_action(std::vector &all_out) + namespace parallel { - for (auto &out : all_out) - out->compress(::dealii::VectorOperation::insert); - } + namespace distributed + { + namespace CellDataTransferImplementation + { + template + void + post_unpack_action(std::vector &all_out) + { + for (auto &out : all_out) + out->compress(::dealii::VectorOperation::insert); + } + + template + void + post_unpack_action(std::vector *> &) + { + // Do nothing for std::vector as VectorType. + } + } // namespace CellDataTransferImplementation + } // namespace distributed + } // namespace parallel +} // namespace internal - template - void - post_refinement_action(std::vector *> &) - { - // Do nothing for std::vector as VectorType. - } -} // namespace namespace parallel @@ -212,7 +222,8 @@ namespace parallel std::placeholders::_3, std::ref(all_out))); - post_refinement_action(all_out); + dealii::internal::parallel::distributed::CellDataTransferImplementation:: + post_unpack_action(all_out); input_vectors.clear(); } diff --git a/source/hp/dof_handler.cc b/source/hp/dof_handler.cc index 1b67554d37..a94637d7af 100644 --- a/source/hp/dof_handler.cc +++ b/source/hp/dof_handler.cc @@ -991,10 +991,10 @@ namespace internal communicate_active_fe_indices( dealii::hp::DoFHandler &dof_handler) { - if (const parallel::shared::Triangulation *tr = + if (const dealii::parallel::shared::Triangulation *tr = dynamic_cast< - const parallel::shared::Triangulation *>( - &dof_handler.get_triangulation())) + const dealii::parallel::shared::Triangulation + *>(&dof_handler.get_triangulation())) { // we have a shared triangulation. in this case, every processor // knows about all cells, but every processor only has knowledge @@ -1029,10 +1029,11 @@ namespace internal cell->index(), active_fe_indices[cell->active_cell_index()]); } - else if (const parallel::distributed::Triangulation - *tr = dynamic_cast< - const parallel::distributed::Triangulation - *>(&dof_handler.get_triangulation())) + else if (const dealii::parallel::distributed::Triangulation + *tr = dynamic_cast *>( + &dof_handler.get_triangulation())) { // For completely distributed meshes, use the function that is // able to move data from locally owned cells on one processor to @@ -1068,10 +1069,10 @@ namespace internal else { // a sequential triangulation. there is nothing we need to do here - Assert( - (dynamic_cast *>( - &dof_handler.get_triangulation()) == nullptr), - ExcInternalError()); + Assert((dynamic_cast< + const dealii::parallel::Triangulation *>( + &dof_handler.get_triangulation()) == nullptr), + ExcInternalError()); } } -- 2.39.5