Skip to content

Commit

Permalink
Merge pull request dealii#18114 from bangerth/mpi-stub
Browse files Browse the repository at this point in the history
Put the declarations in mpi_stub.h into namespace dealii.
  • Loading branch information
marcfehling authored Feb 11, 2025
2 parents 1aaea8a + c300f02 commit 4b952da
Showing 1 changed file with 9 additions and 3 deletions.
12 changes: 9 additions & 3 deletions include/deal.II/base/mpi_stub.h
Original file line number Diff line number Diff line change
Expand Up @@ -24,9 +24,13 @@
#if defined(DEAL_II_WITH_MPI)
# include <mpi.h>
#else
// without MPI, we would still like to use
// some constructs with MPI data
// types. Therefore, create some dummies

// Without MPI, we would still like to use some constructs with MPI
// data types. Therefore, create some dummies. Since we only ever use
// them inside our own constructs, the right thing to do is to put
// them into namespace dealii:
DEAL_II_NAMESPACE_OPEN

using MPI_Comm = int;
using MPI_Request = int;
using MPI_Datatype = int;
Expand All @@ -41,5 +45,7 @@ constexpr MPI_Op MPI_MAX = 0;
constexpr MPI_Op MPI_SUM = 0;
constexpr MPI_Op MPI_LOR = 0;

DEAL_II_NAMESPACE_CLOSE

#endif
#endif

0 comments on commit 4b952da

Please sign in to comment.