mirror of
https://gitlab.com/square-game-liberation-front/F.E.I.S.git
synced 2025-02-28 23:41:33 +01:00
Update interval_tree.hpp
This commit is contained in:
parent
dcb0614bf6
commit
6adf48cb77
@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
From my own for of : https://github.com/NicoG60/interval-tree
|
From my own fork of https://github.com/NicoG60/interval-tree
|
||||||
( https://github.com/Stepland/interval-tree )
|
( https://github.com/Stepland/interval-tree )
|
||||||
*/
|
*/
|
||||||
|
|
||||||
@ -430,7 +430,7 @@ public:
|
|||||||
template<class P, typename std::enable_if<std::is_convertible<value_type, P&&>::value, int>::type = 0>
|
template<class P, typename std::enable_if<std::is_convertible<value_type, P&&>::value, int>::type = 0>
|
||||||
iterator insert(P&& value)
|
iterator insert(P&& value)
|
||||||
{
|
{
|
||||||
return emplace(std::forward(value));
|
return emplace(std::forward<P>(value));
|
||||||
}
|
}
|
||||||
|
|
||||||
iterator insert(const_iterator hint, const value_type& value)
|
iterator insert(const_iterator hint, const value_type& value)
|
||||||
@ -530,7 +530,7 @@ public:
|
|||||||
if(!root)
|
if(!root)
|
||||||
return 0;
|
return 0;
|
||||||
|
|
||||||
node* n = find(root, key);
|
node* n = _find<node*>(key);
|
||||||
|
|
||||||
if(!n)
|
if(!n)
|
||||||
return 0;
|
return 0;
|
||||||
@ -1211,7 +1211,7 @@ bool operator==(const interval_tree<K, T, C>& lhs,
|
|||||||
auto rit = rhs.cbegin();
|
auto rit = rhs.cbegin();
|
||||||
auto er = rhs.cend();
|
auto er = rhs.cend();
|
||||||
|
|
||||||
while(lit != el && rit != er)
|
for(;lit != el && rit != er; ++lit, ++rit)
|
||||||
{
|
{
|
||||||
if(*lit != *rit)
|
if(*lit != *rit)
|
||||||
return false;
|
return false;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user