summaryrefslogtreecommitdiff
path: root/Source/Core/InputCommon/ControllerInterface
diff options
context:
space:
mode:
authormitaclaw <140017135+mitaclaw@users.noreply.github.com>2024-09-29 11:19:05 -0700
committermitaclaw <140017135+mitaclaw@users.noreply.github.com>2024-10-10 00:53:48 -0700
commitebf7cebc32ac9af28dc2383192b7b14f7aea134f (patch)
tree792a436fe69984534ba5cc17544ad16722ce4e80 /Source/Core/InputCommon/ControllerInterface
parentbcaf665d14c5e20ecc88a8978df19ca73e0e29fc (diff)
Modernize `std::sort` with ranges
Diffstat (limited to 'Source/Core/InputCommon/ControllerInterface')
-rw-r--r--Source/Core/InputCommon/ControllerInterface/MappingCommon.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/Source/Core/InputCommon/ControllerInterface/MappingCommon.cpp b/Source/Core/InputCommon/ControllerInterface/MappingCommon.cpp
index 4acee6a970..1877e8294c 100644
--- a/Source/Core/InputCommon/ControllerInterface/MappingCommon.cpp
+++ b/Source/Core/InputCommon/ControllerInterface/MappingCommon.cpp
@@ -101,7 +101,7 @@ BuildExpression(const std::vector<ciface::Core::DeviceContainer::InputDetection>
}
else
{
- std::sort(alternation.begin(), alternation.end());
+ std::ranges::sort(alternation);
alternations.push_back(fmt::to_string(fmt::join(alternation, "&")));
}
};
@@ -128,7 +128,7 @@ BuildExpression(const std::vector<ciface::Core::DeviceContainer::InputDetection>
handle_release();
// Remove duplicates
- std::sort(alternations.begin(), alternations.end());
+ std::ranges::sort(alternations);
alternations.erase(std::unique(alternations.begin(), alternations.end()), alternations.end());
return fmt::to_string(fmt::join(alternations, "|"));