summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorMaxime Coste <mawww@kakoune.org>2018-12-20 08:58:16 +1100
committerMaxime Coste <mawww@kakoune.org>2019-01-20 22:59:28 +1100
commit7b29192c247bb203d690935041217ec40afe1310 (patch)
tree92b6ad142d141eca9b7bba073ee0bfbe541803cf /src
parent5a8a174f81ec3f875e13c80000278d8fbbc01060 (diff)
Fix use of removed std::random_shuffle
Diffstat (limited to 'src')
-rw-r--r--src/hash_map.cc4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/hash_map.cc b/src/hash_map.cc
index 56189aef..4e45ab26 100644
--- a/src/hash_map.cc
+++ b/src/hash_map.cc
@@ -69,7 +69,7 @@ UnitTest test_hash_map{[] {
ref.push_back({key, value});
map.insert({key, value});
- std::random_shuffle(ref.begin(), ref.end());
+ std::shuffle(ref.begin(), ref.end(), re);
for (auto& elem : ref)
{
auto it = map.find(elem.first);
@@ -89,7 +89,7 @@ void do_profile(size_t count, StringView type)
Vector<size_t> vec;
for (size_t i = 0; i < count; ++i)
vec.push_back(i);
- std::random_shuffle(vec.begin(), vec.end());
+ std::shuffle(vec.begin(), vec.end(), re);
Map map;
auto start = Clock::now();