Skip to content
Snippets Groups Projects
Unverified Commit 93c16305 authored by bunnei's avatar bunnei Committed by GitHub
Browse files

Merge pull request #2159 from lioncash/warn

shader/track: Resolve variable shadowing warnings
parents c07987df c1b2e356
No related branches found
No related tags found
No related merge requests found
...@@ -20,9 +20,9 @@ std::pair<Node, s64> FindOperation(const NodeBlock& code, s64 cursor, ...@@ -20,9 +20,9 @@ std::pair<Node, s64> FindOperation(const NodeBlock& code, s64 cursor,
return {node, cursor}; return {node, cursor};
} }
if (const auto conditional = std::get_if<ConditionalNode>(node)) { if (const auto conditional = std::get_if<ConditionalNode>(node)) {
const auto& code = conditional->GetCode(); const auto& conditional_code = conditional->GetCode();
const auto [found, internal_cursor] = const auto [found, internal_cursor] = FindOperation(
FindOperation(code, static_cast<s64>(code.size() - 1), operation_code); conditional_code, static_cast<s64>(conditional_code.size() - 1), operation_code);
if (found) if (found)
return {found, cursor}; return {found, cursor};
} }
...@@ -58,8 +58,8 @@ Node ShaderIR::TrackCbuf(Node tracked, const NodeBlock& code, s64 cursor) { ...@@ -58,8 +58,8 @@ Node ShaderIR::TrackCbuf(Node tracked, const NodeBlock& code, s64 cursor) {
return nullptr; return nullptr;
} }
if (const auto conditional = std::get_if<ConditionalNode>(tracked)) { if (const auto conditional = std::get_if<ConditionalNode>(tracked)) {
const auto& code = conditional->GetCode(); const auto& conditional_code = conditional->GetCode();
return TrackCbuf(tracked, code, static_cast<s64>(code.size())); return TrackCbuf(tracked, conditional_code, static_cast<s64>(conditional_code.size()));
} }
return nullptr; return nullptr;
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment