From 5e3fde65737e4a9ee5100f25444d4c285dc1451a Mon Sep 17 00:00:00 2001
From: Michael Kuron <mkuron@icp.uni-stuttgart.de>
Date: Wed, 27 Mar 2019 17:18:50 +0100
Subject: [PATCH] Replace remaining uses of boost::ref

---
 apps/benchmarks/PeriodicGranularGas/PeriodicGranularGas.cpp  | 4 ++--
 src/cuda/python/Exports.impl.h                               | 2 +-
 tests/pe_coupling/utility/BodiesForceTorqueContainerTest.cpp | 2 +-
 tests/pe_coupling/utility/PeSubCyclingTest.cpp               | 2 +-
 4 files changed, 5 insertions(+), 5 deletions(-)

diff --git a/apps/benchmarks/PeriodicGranularGas/PeriodicGranularGas.cpp b/apps/benchmarks/PeriodicGranularGas/PeriodicGranularGas.cpp
index 190b13e0d..bb69ca027 100644
--- a/apps/benchmarks/PeriodicGranularGas/PeriodicGranularGas.cpp
+++ b/apps/benchmarks/PeriodicGranularGas/PeriodicGranularGas.cpp
@@ -164,11 +164,11 @@ int main( int argc, char ** argv )
    std::function<void(void)> syncCallWithoutTT;
    if (bNN)
    {
-      syncCallWithoutTT = std::bind( pe::syncNextNeighbors<BodyTuple>, boost::ref(*forest), storageID, &tt, real_c(0.1), false );
+      syncCallWithoutTT = std::bind( pe::syncNextNeighbors<BodyTuple>, std::ref(*forest), storageID, &tt, real_c(0.1), false );
       WALBERLA_LOG_INFO_ON_ROOT("Using NextNeighbor sync!");
    } else if (bSO)
    {
-      syncCallWithoutTT = std::bind( pe::syncShadowOwners<BodyTuple>, boost::ref(*forest), storageID, &tt, real_c(0.1), false );
+      syncCallWithoutTT = std::bind( pe::syncShadowOwners<BodyTuple>, std::ref(*forest), storageID, &tt, real_c(0.1), false );
       WALBERLA_LOG_INFO_ON_ROOT("Using ShadowOwner sync!");
    } else
    {
diff --git a/src/cuda/python/Exports.impl.h b/src/cuda/python/Exports.impl.h
index ada1586f3..b828163ed 100644
--- a/src/cuda/python/Exports.impl.h
+++ b/src/cuda/python/Exports.impl.h
@@ -231,7 +231,7 @@ namespace internal {
 
       auto result = make_shared<boost::python::object>();
       AddToStorageExporter exporter( blocks, name, fs, gl, layout, type, usePitchedMem );
-      python_coupling::for_each_noncopyable_type<GpuFields>( boost::ref(exporter) );
+      python_coupling::for_each_noncopyable_type<GpuFields>( std::ref(exporter) );
 
       if ( ! exporter.successful() ) {
          PyErr_SetString( PyExc_ValueError, "Adding Field failed.");
diff --git a/tests/pe_coupling/utility/BodiesForceTorqueContainerTest.cpp b/tests/pe_coupling/utility/BodiesForceTorqueContainerTest.cpp
index bf84cbe06..dcb3382e6 100644
--- a/tests/pe_coupling/utility/BodiesForceTorqueContainerTest.cpp
+++ b/tests/pe_coupling/utility/BodiesForceTorqueContainerTest.cpp
@@ -90,7 +90,7 @@ int main( int argc, char **argv )
 
    // pe coupling
    const real_t overlap = real_t( 1.5 ) * dx;
-   std::function<void(void)> syncCall = std::bind( pe::syncNextNeighbors<BodyTypeTuple>, boost::ref(blocks->getBlockForest()), bodyStorageID, static_cast<WcTimingTree*>(nullptr), overlap, false );
+   std::function<void(void)> syncCall = std::bind( pe::syncNextNeighbors<BodyTypeTuple>, std::ref(blocks->getBlockForest()), bodyStorageID, static_cast<WcTimingTree*>(nullptr), overlap, false );
 
    // sphere positions for test scenarios
    Vector3<real_t> positionInsideBlock(real_t(10), real_t(10), real_t(10));
diff --git a/tests/pe_coupling/utility/PeSubCyclingTest.cpp b/tests/pe_coupling/utility/PeSubCyclingTest.cpp
index 54268c111..ac538eaf4 100644
--- a/tests/pe_coupling/utility/PeSubCyclingTest.cpp
+++ b/tests/pe_coupling/utility/PeSubCyclingTest.cpp
@@ -99,7 +99,7 @@ int main( int argc, char **argv )
 
    // set up synchronization procedure
    const real_t overlap = real_t( 1.5 ) * dx;
-   std::function<void(void)> syncCall = std::bind( pe::syncNextNeighbors<BodyTypeTuple>, boost::ref(blocks->getBlockForest()), bodyStorageID, static_cast<WcTimingTree*>(nullptr), overlap, false );
+   std::function<void(void)> syncCall = std::bind( pe::syncNextNeighbors<BodyTypeTuple>, std::ref(blocks->getBlockForest()), bodyStorageID, static_cast<WcTimingTree*>(nullptr), overlap, false );
 
 
    // sphere positions for test scenarios
-- 
GitLab