aboutsummaryrefslogtreecommitdiff
path: root/src/common/Asio/Strand.h
diff options
context:
space:
mode:
authorShauren <shauren.trinity@gmail.com>2022-02-14 12:43:57 +0100
committerShauren <shauren.trinity@gmail.com>2022-02-14 12:43:57 +0100
commitf6e72494f185d096f2cce70e646f0761e67e1bc7 (patch)
tree0009a721406f3a97b08a578432a5dd0b7dfb1061 /src/common/Asio/Strand.h
parenta6dd3a1946be27acab80b78b71eecae7dbad82e6 (diff)
Dep: Raise required boost versions to 1.73 on windows and 1.71 on linux and remove compatibility code for unsupported versions
Diffstat (limited to 'src/common/Asio/Strand.h')
-rw-r--r--src/common/Asio/Strand.h17
1 files changed, 3 insertions, 14 deletions
diff --git a/src/common/Asio/Strand.h b/src/common/Asio/Strand.h
index c27407d1a3c..5beef144c60 100644
--- a/src/common/Asio/Strand.h
+++ b/src/common/Asio/Strand.h
@@ -19,11 +19,8 @@
#define Strand_h__
#include "IoContext.h"
-#include <boost/asio/strand.hpp>
-
-#if BOOST_VERSION >= 106600
#include <boost/asio/bind_executor.hpp>
-#endif
+#include <boost/asio/strand.hpp>
namespace Trinity
{
@@ -32,21 +29,13 @@ namespace Trinity
/**
Hack to make it possible to forward declare strand (which is a inner class)
*/
- class Strand : public IoContextBaseNamespace::IoContextBase::strand
+ class Strand : public boost::asio::io_context::strand
{
public:
- Strand(IoContext& ioContext) : IoContextBaseNamespace::IoContextBase::strand(ioContext) { }
+ Strand(IoContext& ioContext) : boost::asio::io_context::strand(ioContext) { }
};
-#if BOOST_VERSION >= 106600
using boost::asio::bind_executor;
-#else
- template<typename T>
- inline decltype(auto) bind_executor(Strand& strand, T&& t)
- {
- return strand.wrap(std::forward<T>(t));
- }
-#endif
}
}