diff options
| author | Lioncash <mathew1800@gmail.com> | 2019-06-01 07:55:09 -0400 |
|---|---|---|
| committer | Lioncash <mathew1800@gmail.com> | 2019-06-01 10:07:57 -0400 |
| commit | a9663669dc1037a04e37ae30efe18c0650547ac5 (patch) | |
| tree | b0bafacb909c3360951bb6b2781a94b97a9284be /Source/Core/VideoBackends/Vulkan/PerfQuery.cpp | |
| parent | a4837a5c5dc5d71f4b93dcb2fd5b80c5cfab381a (diff) | |
Common/CommonFuncs: Remove now-unneccessary ArraySize function
Since C++17, non-member std::size() is present in the standard library
which also operates on regular C arrays. Given that, we can just replace
usages of ArraySize with that where applicable.
In many cases, we can just change the actual C array ArraySize() was
called on into a std::array and just use its .size() member function
instead.
In some other cases, we can collapse the loops they were used in, into a
ranged-for loop, eliminating the need for en explicit bounds query.
Diffstat (limited to 'Source/Core/VideoBackends/Vulkan/PerfQuery.cpp')
| -rw-r--r-- | Source/Core/VideoBackends/Vulkan/PerfQuery.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Source/Core/VideoBackends/Vulkan/PerfQuery.cpp b/Source/Core/VideoBackends/Vulkan/PerfQuery.cpp index e13c02173d..6c64d71b2e 100644 --- a/Source/Core/VideoBackends/Vulkan/PerfQuery.cpp +++ b/Source/Core/VideoBackends/Vulkan/PerfQuery.cpp @@ -81,7 +81,7 @@ void PerfQuery::ResetQuery() m_query_count = 0; m_query_readback_pos = 0; m_query_next_pos = 0; - std::fill_n(m_results, ArraySize(m_results), 0); + std::fill(std::begin(m_results), std::end(m_results), 0); // Reset entire query pool, ensuring all queries are ready to write to. StateTracker::GetInstance()->EndRenderPass(); |
