migrate to std::ranges
Move the various seq_ functions, as well as std::(stable_)sort, std::accumulate, std::transform, std::find, std::find_if to their C++20 std::ranges counterparts.
This commit is contained in:
@ -125,9 +125,7 @@ Mu::script_infos(const Mu::ScriptPaths& paths)
|
||||
script_infos_in_dir(dir, infos);
|
||||
}
|
||||
|
||||
std::sort(infos.begin(), infos.end(), [](auto&& i1, auto&& i2) {
|
||||
return i1.name < i2.name;
|
||||
});
|
||||
std::ranges::sort(infos, {}, &ScriptInfo::name);
|
||||
|
||||
return infos;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user