From 6d2d0c8ee59eed641937b19cf19a1ff08762cbfa Mon Sep 17 00:00:00 2001
From: Nat Goodspeed <nat@lindenlab.com>
Date: Fri, 2 Jun 2023 17:27:57 -0400
Subject: [PATCH] SL-18837: Boost.Bind _1, _2 placeholders are no longer
 global.

This was a longstanding complaint: that Boost shouldn't dump the (somewhat
mysterious) _1, _2 et al. names into the global namespace. Recent Boost has
fixed that, requiring 'using namespace boost::placeholders;' if you want to
use them unqualified.
---
 indra/llinventory/llsettingsbase.cpp  | 4 ++++
 indra/llinventory/llsettingssky.cpp   | 4 ++++
 indra/llinventory/llsettingswater.cpp | 4 ++++
 3 files changed, 12 insertions(+)

diff --git a/indra/llinventory/llsettingsbase.cpp b/indra/llinventory/llsettingsbase.cpp
index 936b166409f..ba338dbbee1 100644
--- a/indra/llinventory/llsettingsbase.cpp
+++ b/indra/llinventory/llsettingsbase.cpp
@@ -31,6 +31,10 @@
 #include <algorithm>
 
 #include "llsdserialize.h"
+#include <boost/bind.hpp>
+
+// allow unqualified _1, _2 et al. to mean boost::bind placeholders
+using namespace boost::placeholders;
 
 //=========================================================================
 namespace
diff --git a/indra/llinventory/llsettingssky.cpp b/indra/llinventory/llsettingssky.cpp
index a129f0a6f07..0244b2585e9 100644
--- a/indra/llinventory/llsettingssky.cpp
+++ b/indra/llinventory/llsettingssky.cpp
@@ -31,6 +31,10 @@
 #include "lltrace.h"
 #include "llfasttimer.h"
 #include "v3colorutil.h"
+#include <boost/bind.hpp>
+
+// allow unqualified _1, _2 et al. to mean boost::bind placeholders
+using namespace boost::placeholders;
 
 //=========================================================================
 namespace
diff --git a/indra/llinventory/llsettingswater.cpp b/indra/llinventory/llsettingswater.cpp
index d732032a6c5..bc53a46255b 100644
--- a/indra/llinventory/llsettingswater.cpp
+++ b/indra/llinventory/llsettingswater.cpp
@@ -32,6 +32,10 @@
 #include "llfasttimer.h"
 #include "v3colorutil.h"
 #include "indra_constants.h"
+#include <boost/bind.hpp>
+
+// allow unqualified _1, _2 et al. to mean boost::bind placeholders
+using namespace boost::placeholders;
 
 const std::string LLSettingsWater::SETTING_BLUR_MULTIPLIER("blur_multiplier");
 const std::string LLSettingsWater::SETTING_FOG_COLOR("water_fog_color");
-- 
GitLab