Skip to content

Commit

Permalink
Merge pull request dealii#18056 from bangerth/debug
Browse files Browse the repository at this point in the history
Fix '#if DEBUG' statements.
  • Loading branch information
marcfehling authored Jan 30, 2025
2 parents dc8fa85 + ce667ca commit 23b9dc3
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion include/deal.II/fe/fe_tools.templates.h
Original file line number Diff line number Diff line change
Expand Up @@ -2233,7 +2233,7 @@ namespace FETools
// Ensure that the element we are looking for isn't in the map
// yet. This only requires us to read the map, so it can happen
// in a shared locked state
#if DEBUG
#ifdef DEBUG
{
std::shared_lock<std::shared_mutex> lock(
internal::FEToolsAddFENameHelper::fe_name_map_lock);
Expand Down
4 changes: 2 additions & 2 deletions source/grid/tria_description.cc
Original file line number Diff line number Diff line change
Expand Up @@ -734,14 +734,14 @@ namespace TriangulationDescription
"in the given communicator."));
}

#ifdef DEBUG
// If we are dealing with a sequential triangulation, then someone
// will have needed to set the subdomain_ids by hand. Make sure that
// all ids we see are less than the number of processes we are
// supposed to split the triangulation into.
if (dynamic_cast<const parallel::TriangulationBase<dim, spacedim> *>(
&tria) == nullptr)
{
#if DEBUG
const unsigned int n_mpi_processes =
dealii::Utilities::MPI::n_mpi_processes(comm);
for (const auto &cell : tria.active_cell_iterators())
Expand All @@ -751,8 +751,8 @@ namespace TriangulationDescription
" when splitting the triangulation using an MPI "
" communicator with only " +
std::to_string(n_mpi_processes) + " processes."));
#endif
}
#endif

// First, figure out for what rank we are supposed to build the
// TriangulationDescription::Description object
Expand Down

0 comments on commit 23b9dc3

Please sign in to comment.