|
8 | 8 | #pragma once |
9 | 9 |
|
10 | 10 | #include <algorithm> |
| 11 | +#include <boost/algorithm/cxx14/equal.hpp> |
11 | 12 | #include <boost/convert.hpp> |
12 | 13 | #include <boost/convert/lexical_cast.hpp> |
13 | 14 | #include <cctype> |
@@ -81,21 +82,22 @@ class equality : public boost::static_visitor<bool> { |
81 | 82 | } |
82 | 83 |
|
83 | 84 | bool operator()(const markers::string_t<Iterator> &value) const { |
84 | | - auto helper = stringizer<Iterator>(); |
85 | | - auto str = helper(value); |
86 | | - return std::equal(begin_, end_, value.from, value.to); |
| 85 | + return boost::algorithm::equal(begin_, end_, value.from, value.to); |
87 | 86 | } |
88 | 87 |
|
89 | 88 | bool operator()(const markers::int_t<Iterator> &value) const { |
90 | | - return std::equal(begin_, end_, value.string.from, value.string.to); |
| 89 | + return boost::algorithm::equal(begin_, end_, value.string.from, |
| 90 | + value.string.to); |
91 | 91 | } |
92 | 92 |
|
93 | 93 | bool operator()(const markers::error_t<Iterator> &value) const { |
94 | | - return std::equal(begin_, end_, value.string.from, value.string.to); |
| 94 | + return boost::algorithm::equal(begin_, end_, value.string.from, |
| 95 | + value.string.to); |
95 | 96 | } |
96 | 97 |
|
97 | 98 | bool operator()(const markers::nil_t<Iterator> &value) const { |
98 | | - return std::equal(begin_, end_, value.string.from, value.string.to); |
| 99 | + return boost::algorithm::equal(begin_, end_, value.string.from, |
| 100 | + value.string.to); |
99 | 101 | } |
100 | 102 | }; |
101 | 103 |
|
@@ -172,8 +174,8 @@ class check_subscription : public boost::static_visitor<bool> { |
172 | 174 | } |
173 | 175 |
|
174 | 176 | const auto &channel_ = cmd_.arguments[idx]; |
175 | | - return std::equal(channel_.cbegin(), channel_.cend(), channel->from, |
176 | | - channel->to); |
| 177 | + return boost::algorithm::equal(channel_.cbegin(), channel_.cend(), |
| 178 | + channel->from, channel->to); |
177 | 179 | } |
178 | 180 | return false; |
179 | 181 | } |
|
0 commit comments