diff options
| author | Lioncash <mathew1800@gmail.com> | 2020-12-07 16:30:36 -0500 |
|---|---|---|
| committer | Lioncash <mathew1800@gmail.com> | 2020-12-07 16:30:39 -0500 |
| commit | 909671a055dc344cbda08288c6bc59df732bc1a2 (patch) | |
| tree | 3ea0bbe356d45a250b1b5300773bc2c419a39c19 /src/video_core/shader/decode.cpp | |
| parent | 72378f4f6c3e6dcd85ee96740aba54027fd1d324 (diff) | |
video_core: Make use of ordered container contains() where applicable
With C++20, we can use the more concise contains() member function
instead of comparing the result of the find() call with the end
iterator.
Diffstat (limited to 'src/video_core/shader/decode.cpp')
| -rw-r--r-- | src/video_core/shader/decode.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/video_core/shader/decode.cpp b/src/video_core/shader/decode.cpp index c8f4da6dff..ab14c1aa39 100644 --- a/src/video_core/shader/decode.cpp +++ b/src/video_core/shader/decode.cpp @@ -153,8 +153,8 @@ void ShaderIR::Decode() { const auto& blocks = shader_info.blocks; NodeBlock current_block; u32 current_label = static_cast<u32>(exit_branch); - for (auto& block : blocks) { - if (shader_info.labels.count(block.start) != 0) { + for (const auto& block : blocks) { + if (shader_info.labels.contains(block.start)) { insert_block(current_block, current_label); current_block.clear(); current_label = block.start; |
