diff options
| author | JMC47 <JMC4789@gmail.com> | 2025-03-23 15:56:13 -0400 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2025-03-23 15:56:13 -0400 |
| commit | ad3650abfcae6432338ba976123958ee67a4106c (patch) | |
| tree | 23def284c9a42648ea0779f94903ba43903aa353 /Source/Core/Common/Config/Config.cpp | |
| parent | 1515cf6ccdd1ba206c8e0eaabad07de28a4f5939 (diff) | |
| parent | e4efe011d71b668537bc551996848e911de079ab (diff) | |
Merge pull request #13093 from mitaclaw/ranges-modernization-4-projection
Ranges Algorithms Modernization - Projection
Diffstat (limited to 'Source/Core/Common/Config/Config.cpp')
| -rw-r--r-- | Source/Core/Common/Config/Config.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/Source/Core/Common/Config/Config.cpp b/Source/Core/Common/Config/Config.cpp index 00dbab7bb4..b1e591ddac 100644 --- a/Source/Core/Common/Config/Config.cpp +++ b/Source/Core/Common/Config/Config.cpp @@ -11,6 +11,8 @@ #include <utility> #include <vector> +#include "Common/Projection.h" + namespace Config { using Layers = std::map<LayerType, std::shared_ptr<Layer>>; @@ -168,8 +170,7 @@ const std::string& GetSystemName(System system) std::optional<System> GetSystemFromName(const std::string& name) { - const auto system = std::find_if(system_to_name.begin(), system_to_name.end(), - [&name](const auto& entry) { return entry.second == name; }); + const auto system = std::ranges::find(system_to_name, name, Common::Projection::Value{}); if (system != system_to_name.end()) return system->first; |
