4545#include < unordered_set>
4646#include < utility>
4747
48+ struct less {
49+ template <class T , class U >
50+ bool operator ()(const T& x, const U& y) const {
51+ return x < y;
52+ }
53+ };
54+
4855const std::list<ValueFlow::Value> TokenImpl::mEmptyValueList ;
4956
5057Token::Token (TokensFrontBack *tokensFrontBack) :
@@ -1921,7 +1928,7 @@ static bool removeContradiction(std::list<ValueFlow::Value>& values)
19211928 continue ;
19221929 if (!x.equalValue (y)) {
19231930 auto compare = [](const ValueFlow::Value& x, const ValueFlow::Value& y) {
1924- return x.compareValue (y, ValueFlow:: less{});
1931+ return x.compareValue (y, less{});
19251932 };
19261933 const ValueFlow::Value& maxValue = std::max (x, y, compare);
19271934 const ValueFlow::Value& minValue = std::min (x, y, compare);
@@ -2012,9 +2019,9 @@ static void mergeAdjacent(std::list<ValueFlow::Value>& values)
20122019 if (y->bound != ValueFlow::Value::Bound::Point)
20132020 continue ;
20142021 }
2015- if (x->bound == ValueFlow::Value::Bound::Lower && !y->compareValue (*x, ValueFlow:: less{}))
2022+ if (x->bound == ValueFlow::Value::Bound::Lower && !y->compareValue (*x, less{}))
20162023 continue ;
2017- if (x->bound == ValueFlow::Value::Bound::Upper && !x->compareValue (*y, ValueFlow:: less{}))
2024+ if (x->bound == ValueFlow::Value::Bound::Upper && !x->compareValue (*y, less{}))
20182025 continue ;
20192026 adjValues.push_back (y);
20202027 }
@@ -2025,7 +2032,7 @@ static void mergeAdjacent(std::list<ValueFlow::Value>& values)
20252032 std::sort (adjValues.begin (), adjValues.end (), [&values](ValueIterator xx, ValueIterator yy) {
20262033 (void )values;
20272034 assert (xx != values.end () && yy != values.end ());
2028- return xx->compareValue (*yy, ValueFlow:: less{});
2035+ return xx->compareValue (*yy, less{});
20292036 });
20302037 if (x->bound == ValueFlow::Value::Bound::Lower)
20312038 x = removeAdjacentValues (values, x, adjValues.rbegin (), adjValues.rend ());
0 commit comments