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:
mitaclaw
2024-08-22 19:16:36 -07:00
parent a7160c7b38
commit 9bd1dae41d
8 changed files with 20 additions and 20 deletions

View File

@ -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()