mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-06-11 16:49:28 +02:00
Modernize std::unique
with ranges
The new return value is `std::ranges::subrange`.
This commit is contained in:
@ -129,7 +129,8 @@ BuildExpression(const std::vector<ciface::Core::DeviceContainer::InputDetection>
|
||||
|
||||
// Remove duplicates
|
||||
std::ranges::sort(alternations);
|
||||
alternations.erase(std::unique(alternations.begin(), alternations.end()), alternations.end());
|
||||
const auto unique_result = std::ranges::unique(alternations);
|
||||
alternations.erase(unique_result.begin(), unique_result.end());
|
||||
|
||||
return fmt::to_string(fmt::join(alternations, "|"));
|
||||
}
|
||||
|
Reference in New Issue
Block a user