mirror of
https://github.com/cemu-project/vcpkg.git
synced 2024-11-23 19:29:49 +00:00
Fix SortedVector constructor
This commit is contained in:
parent
35ccbc869b
commit
f6840ab268
@ -13,7 +13,7 @@ namespace vcpkg
|
||||
using size_type = typename std::vector<T>::size_type;
|
||||
using iterator = typename std::vector<T>::const_iterator;
|
||||
|
||||
explicit SortedVector<T>(std::vector<T> v) : m_data(std::move(v))
|
||||
explicit SortedVector(std::vector<T> v) : m_data(std::move(v))
|
||||
{
|
||||
if (!std::is_sorted(m_data.begin(), m_data.end()))
|
||||
{
|
||||
@ -21,7 +21,7 @@ namespace vcpkg
|
||||
}
|
||||
}
|
||||
template <class Compare>
|
||||
SortedVector<T>(std::vector<T> v, Compare comp) : m_data(std::move(v))
|
||||
SortedVector(std::vector<T> v, Compare comp) : m_data(std::move(v))
|
||||
{
|
||||
if (!std::is_sorted(m_data.cbegin(), m_data.cend(), comp))
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user