mirror of
https://github.com/ETLCPP/etl.git
synced 2026-06-15 08:26:04 +08:00
Try to fix C++03 build.
This commit is contained in:
parent
ba905f98be
commit
9bcdf3082d
@ -821,7 +821,7 @@ namespace etl
|
|||||||
while (first != last)
|
while (first != last)
|
||||||
{
|
{
|
||||||
link_type& link = *first++;
|
link_type& link = *first++;
|
||||||
auto& value = static_cast<TValue&>(link);
|
TValue& value = static_cast<TValue&>(link);
|
||||||
#if ETL_USING_CPP11
|
#if ETL_USING_CPP11
|
||||||
find_or_insert_impl<TValue>( //
|
find_or_insert_impl<TValue>( //
|
||||||
[&value, &binary_comp](const TValue& other) { return binary_comp(value, other); }, //
|
[&value, &binary_comp](const TValue& other) { return binary_comp(value, other); }, //
|
||||||
@ -840,8 +840,8 @@ namespace etl
|
|||||||
TLink* curr = root;
|
TLink* curr = root;
|
||||||
while (ETL_NULLPTR != curr)
|
while (ETL_NULLPTR != curr)
|
||||||
{
|
{
|
||||||
auto* const result = static_cast<TValue*>(curr);
|
TValue* const result = static_cast<TValue*>(curr);
|
||||||
const int cmp = comp(*result);
|
const int cmp = comp(*result);
|
||||||
if (0 == cmp)
|
if (0 == cmp)
|
||||||
{
|
{
|
||||||
// Found!
|
// Found!
|
||||||
@ -864,8 +864,8 @@ namespace etl
|
|||||||
link_type* parent = &origin;
|
link_type* parent = &origin;
|
||||||
while (ETL_NULLPTR != curr)
|
while (ETL_NULLPTR != curr)
|
||||||
{
|
{
|
||||||
auto* const result = static_cast<TValue*>(curr);
|
TValue* const result = static_cast<TValue*>(curr);
|
||||||
const int cmp = comp(*result);
|
const int cmp = comp(*result);
|
||||||
if (0 == cmp)
|
if (0 == cmp)
|
||||||
{
|
{
|
||||||
// Found! Tree was not modified.
|
// Found! Tree was not modified.
|
||||||
@ -905,8 +905,8 @@ namespace etl
|
|||||||
TLink* next = root;
|
TLink* next = root;
|
||||||
while (ETL_NULLPTR != next)
|
while (ETL_NULLPTR != next)
|
||||||
{
|
{
|
||||||
auto* const next_value = static_cast<TValue*>(next);
|
TValue* const next_value = static_cast<TValue*>(next);
|
||||||
const int cmp = comp(*next_value);
|
const int cmp = comp(*next_value);
|
||||||
if ((cmp > 0) || (IsUpper && (cmp == 0)))
|
if ((cmp > 0) || (IsUpper && (cmp == 0)))
|
||||||
{
|
{
|
||||||
next = next->get_right();
|
next = next->get_right();
|
||||||
@ -1213,7 +1213,7 @@ namespace etl
|
|||||||
return !(lhs == rhs);
|
return !(lhs == rhs);
|
||||||
}
|
}
|
||||||
|
|
||||||
explicit operator bool() const ETL_NOEXCEPT
|
ETL_EXPLICIT operator bool() const ETL_NOEXCEPT
|
||||||
{
|
{
|
||||||
return has_value();
|
return has_value();
|
||||||
}
|
}
|
||||||
@ -1262,7 +1262,7 @@ namespace etl
|
|||||||
|
|
||||||
private:
|
private:
|
||||||
|
|
||||||
explicit iterator(link_type* value)
|
ETL_EXPLICIT iterator(link_type* value)
|
||||||
: p_value(value)
|
: p_value(value)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
@ -1393,7 +1393,7 @@ namespace etl
|
|||||||
return !(lhs == rhs);
|
return !(lhs == rhs);
|
||||||
}
|
}
|
||||||
|
|
||||||
explicit operator bool() const ETL_NOEXCEPT
|
ETL_EXPLICIT operator bool() const ETL_NOEXCEPT
|
||||||
{
|
{
|
||||||
return has_value();
|
return has_value();
|
||||||
}
|
}
|
||||||
@ -1442,7 +1442,7 @@ namespace etl
|
|||||||
|
|
||||||
private:
|
private:
|
||||||
|
|
||||||
explicit const_iterator(const link_type* value)
|
ETL_EXPLICIT const_iterator(const link_type* value)
|
||||||
: p_value(value)
|
: p_value(value)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
@ -1498,7 +1498,7 @@ namespace etl
|
|||||||
/// Destructor.
|
/// Destructor.
|
||||||
/// Complexity: O(N).
|
/// Complexity: O(N).
|
||||||
//*************************************************************************
|
//*************************************************************************
|
||||||
~intrusive_avl_tree() = default;
|
~intrusive_avl_tree() {}
|
||||||
|
|
||||||
#if ETL_USING_CPP11
|
#if ETL_USING_CPP11
|
||||||
//*************************************************************************
|
//*************************************************************************
|
||||||
@ -1984,7 +1984,7 @@ namespace etl
|
|||||||
struct CastingVisitor
|
struct CastingVisitor
|
||||||
{
|
{
|
||||||
Visitor& visitor;
|
Visitor& visitor;
|
||||||
explicit CastingVisitor(Visitor& visitor)
|
ETL_EXPLICIT CastingVisitor(Visitor& visitor)
|
||||||
: visitor(visitor)
|
: visitor(visitor)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user