mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-06-13 00:58:29 +02:00
Modernize std::fill
with ranges
In DSPCore.cpp, there were two `std::fill` uses that could be simplified using `std::fill_n`. Due to their proximity with other `std::fill` algorithms being modernized with ranges, I chose to make these examples into the rare `std::ranges::fill_n`.
This commit is contained in:
@ -183,7 +183,7 @@ Joystick::Joystick(const LPDIRECTINPUTDEVICE8 device) : m_device(device)
|
||||
|
||||
// Set hats to center:
|
||||
// "The center position is normally reported as -1" -MSDN
|
||||
std::fill(std::begin(m_state_in.rgdwPOV), std::end(m_state_in.rgdwPOV), -1);
|
||||
std::ranges::fill(m_state_in.rgdwPOV, -1);
|
||||
}
|
||||
|
||||
Joystick::~Joystick()
|
||||
|
Reference in New Issue
Block a user