From cfd9ef6265f77e7ad886f97d6497fbe2660666f0 Mon Sep 17 00:00:00 2001 From: Doug Shi-Dong Date: Thu, 30 Apr 2020 23:32:53 -0400 Subject: [PATCH] Pass arg by value in create_ascending_partitioning As per https://github.com/dealii/dealii/pull/9991#issuecomment-622199929. --- include/deal.II/base/mpi.h | 4 ++-- source/base/mpi.cc | 6 +++--- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/include/deal.II/base/mpi.h b/include/deal.II/base/mpi.h index 589260d15c..68bdb8e12b 100644 --- a/include/deal.II/base/mpi.h +++ b/include/deal.II/base/mpi.h @@ -428,8 +428,8 @@ namespace Utilities * process p. */ std::vector - create_ascending_partitioning(const MPI_Comm & comm, - const IndexSet::size_type &local_size); + create_ascending_partitioning(const MPI_Comm & comm, + const IndexSet::size_type local_size); #ifdef DEAL_II_WITH_MPI /** diff --git a/source/base/mpi.cc b/source/base/mpi.cc index f8cddf8b7f..9295a2c0c8 100644 --- a/source/base/mpi.cc +++ b/source/base/mpi.cc @@ -222,8 +222,8 @@ namespace Utilities std::vector - create_ascending_partitioning(const MPI_Comm & comm, - const IndexSet::size_type &local_size) + create_ascending_partitioning(const MPI_Comm & comm, + const IndexSet::size_type local_size) { const unsigned int n_proc = n_mpi_processes(comm); const std::vector sizes = @@ -659,7 +659,7 @@ namespace Utilities std::vector create_ascending_partitioning(const MPI_Comm & /*comm*/, - const IndexSet::size_type &local_size) + const IndexSet::size_type local_size) { return std::vector(1, complete_index_set(local_size)); } -- 2.39.5