Remove unused bubble sort (finally)

This commit is contained in:
def 2022-04-02 18:30:03 +02:00
parent 7546ee715f
commit e4bec352d9

View file

@ -76,36 +76,6 @@ R find_binary(R range, T value)
return R();
}
template<class R>
void sort_bubble(R range)
{
concept_empty::check(range);
concept_forwarditeration::check(range);
concept_backwarditeration::check(range);
// slow bubblesort :/
for(; !range.empty(); range.pop_back())
{
R section = range;
typename R::type *prev = &section.front();
section.pop_front();
for(; !section.empty(); section.pop_front())
{
typename R::type *cur = &section.front();
if(*cur < *prev)
swap(*cur, *prev);
prev = cur;
}
}
}
/*
template<class R>
void sort_quick(R range)
{
concept_index::check(range);
}*/
template<class R>
void sort(R range)
{