summaryrefslogtreecommitdiff
path: root/indra/llcommon/lldoubledispatch.h
diff options
context:
space:
mode:
authorRye <rye@alchemyviewer.org>2025-12-01 05:46:57 -0500
committerGitHub <noreply@github.com>2025-12-01 12:46:57 +0200
commitfb3f0e18a2ada57f98c3b10fab0c13fb2d504ae1 (patch)
treef554227f66bc9d54ae78bb63a816e72d5575ae82 /indra/llcommon/lldoubledispatch.h
parentafb1f4d692bb593b3f200d490dd3f8fdeab8d279 (diff)
#5078 Replace boost::function with std::function
* Replace boost::function usage with std::function for easier debugging and reduced compiler warnings * Remove a few remaining instances of boost::noncopyable that were missed in tests Signed-off-by: Rye <rye@alchemyviewer.org>
Diffstat (limited to 'indra/llcommon/lldoubledispatch.h')
-rw-r--r--indra/llcommon/lldoubledispatch.h14
1 files changed, 6 insertions, 8 deletions
diff --git a/indra/llcommon/lldoubledispatch.h b/indra/llcommon/lldoubledispatch.h
index 25039c3e9c..ad4dc57d58 100644
--- a/indra/llcommon/lldoubledispatch.h
+++ b/indra/llcommon/lldoubledispatch.h
@@ -30,9 +30,7 @@
#define LL_LLDOUBLEDISPATCH_H
#include <list>
-#include <boost/function.hpp>
-#include <boost/bind.hpp>
-#include <boost/ref.hpp>
+#include <functional>
/**
* This class supports function calls which are virtual on the dynamic type of
@@ -156,9 +154,9 @@ public:
insert(t1, t2, func);
if (symmetrical)
{
- // Use boost::bind() to construct a param-swapping thunk. Don't
+ // Use std::bind() to construct a param-swapping thunk. Don't
// forget to reverse the parameters too.
- insert(t2, t1, boost::bind(func, _2, _1));
+ insert(t2, t1, std::bind(func, std::placeholders::_2, std::placeholders::_1));
}
}
@@ -193,7 +191,7 @@ public:
insert(Type<Type1>(), Type<Type2>(), func, insertion);
if (symmetrical)
{
- insert(Type<Type2>(), Type<Type1>(), boost::bind(func, _2, _1), insertion);
+ insert(Type<Type2>(), Type<Type1>(), std::bind(func, std::placeholders::_2, std::placeholders::_1), insertion);
}
}
@@ -271,8 +269,8 @@ private:
typename DispatchTable::iterator find(const ParamBaseType& param1, const ParamBaseType& param2)
{
return std::find_if(mDispatch.begin(), mDispatch.end(),
- boost::bind(&EntryBase::matches, _1,
- boost::ref(param1), boost::ref(param2)));
+ std::bind(&EntryBase::matches, std::placeholders::_1,
+ std::ref(param1), std::ref(param2)));
}
/// Look up the first matching entry.