summaryrefslogtreecommitdiff
path: root/src/video_core/shader/decode.cpp
diff options
context:
space:
mode:
authorGravatar Lioncash2020-12-07 16:30:36 -0500
committerGravatar Lioncash2020-12-07 16:30:39 -0500
commit09fa1d6a739b18f6a8f3d83065ff9aebd6e4bc8d (patch)
tree3ea0bbe356d45a250b1b5300773bc2c419a39c19 /src/video_core/shader/decode.cpp
parentMerge pull request #5149 from comex/xx-map-interval (diff)
downloadyuzu-09fa1d6a739b18f6a8f3d83065ff9aebd6e4bc8d.tar.gz
yuzu-09fa1d6a739b18f6a8f3d83065ff9aebd6e4bc8d.tar.xz
yuzu-09fa1d6a739b18f6a8f3d83065ff9aebd6e4bc8d.zip
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.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/video_core/shader/decode.cpp b/src/video_core/shader/decode.cpp
index c8f4da6df..ab14c1aa3 100644
--- a/src/video_core/shader/decode.cpp
+++ b/src/video_core/shader/decode.cpp
@@ -153,8 +153,8 @@ void ShaderIR::Decode() {
153 const auto& blocks = shader_info.blocks; 153 const auto& blocks = shader_info.blocks;
154 NodeBlock current_block; 154 NodeBlock current_block;
155 u32 current_label = static_cast<u32>(exit_branch); 155 u32 current_label = static_cast<u32>(exit_branch);
156 for (auto& block : blocks) { 156 for (const auto& block : blocks) {
157 if (shader_info.labels.count(block.start) != 0) { 157 if (shader_info.labels.contains(block.start)) {
158 insert_block(current_block, current_label); 158 insert_block(current_block, current_label);
159 current_block.clear(); 159 current_block.clear();
160 current_label = block.start; 160 current_label = block.start;