Fix BorlandC compilation
Rename partition to partition3 to resolve conflicts with std::partition.
This commit is contained in:
parent
bd23216420
commit
b6995f06b9
@ -7262,7 +7262,7 @@ PUGI__NS_BEGIN
|
|||||||
return middle;
|
return middle;
|
||||||
}
|
}
|
||||||
|
|
||||||
template <typename T, typename Pred> void partition(T* begin, T* end, T pivot, const Pred& pred, T** out_eqbeg, T** out_eqend)
|
template <typename T, typename Pred> void partition3(T* begin, T* end, T pivot, const Pred& pred, T** out_eqbeg, T** out_eqend)
|
||||||
{
|
{
|
||||||
// invariant: array is split into 4 groups: = < ? > (each variable denotes the boundary between the groups)
|
// invariant: array is split into 4 groups: = < ? > (each variable denotes the boundary between the groups)
|
||||||
T* eq = begin;
|
T* eq = begin;
|
||||||
@ -7300,7 +7300,7 @@ PUGI__NS_BEGIN
|
|||||||
|
|
||||||
// partition in three chunks (< = >)
|
// partition in three chunks (< = >)
|
||||||
I eqbeg, eqend;
|
I eqbeg, eqend;
|
||||||
partition(begin, end, *median, pred, &eqbeg, &eqend);
|
partition3(begin, end, *median, pred, &eqbeg, &eqend);
|
||||||
|
|
||||||
// loop on larger half
|
// loop on larger half
|
||||||
if (eqbeg - begin > end - eqend)
|
if (eqbeg - begin > end - eqend)
|
||||||
|
|||||||
@ -809,7 +809,7 @@ TEST(xpath_unknown_functions)
|
|||||||
query[0] = ch;
|
query[0] = ch;
|
||||||
CHECK_XPATH_FAIL(query);
|
CHECK_XPATH_FAIL(query);
|
||||||
|
|
||||||
query[0] = ch - 32;
|
query[0] = char_t(ch - 32);
|
||||||
CHECK_XPATH_FAIL(query);
|
CHECK_XPATH_FAIL(query);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user