Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/KhronosGroup/SPIRV-Cross.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHans-Kristian Arntzen <post@arntzen-software.no>2022-11-02 14:14:31 +0300
committerHans-Kristian Arntzen <post@arntzen-software.no>2022-11-02 14:15:10 +0300
commit892f65b3a6488690cb5917dff04ab6134fea2e20 (patch)
tree0e908f6a9193791e5ef8941663811edb801e87d9
parenta4d5c0c4a53904784e749971d309dfa4faef0fc8 (diff)
HLSL: Fix some warnings from review.
-rw-r--r--spirv_hlsl.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/spirv_hlsl.cpp b/spirv_hlsl.cpp
index 5564d479..c2de3a8f 100644
--- a/spirv_hlsl.cpp
+++ b/spirv_hlsl.cpp
@@ -2312,7 +2312,7 @@ void CompilerHLSL::analyze_meshlet_writes()
uint32_t id_per_primitive = 0;
bool need_per_primitive = false;
- ir.for_each_typed_id<SPIRVariable>([&](uint32_t id, SPIRVariable &var) {
+ ir.for_each_typed_id<SPIRVariable>([&](uint32_t, SPIRVariable &var) {
auto &type = this->get<SPIRType>(var.basetype);
bool block = has_decoration(type.self, DecorationBlock);
if (var.storage == StorageClassOutput && block && is_builtin_variable(var))
@@ -2441,8 +2441,8 @@ void CompilerHLSL::analyze_meshlet_writes(uint32_t func_id, uint32_t id_per_vert
m->decoration.builtin_type != BuiltInPrimitiveLineIndicesEXT &&
m->decoration.builtin_type != BuiltInPrimitiveTriangleIndicesEXT)
{
- bool block = has_decoration(base_type.self, DecorationBlock);
- auto flags = block ? get_buffer_block_flags(var.self) : Bitset();
+ bool is_block = has_decoration(base_type.self, DecorationBlock);
+ auto flags = is_block ? get_buffer_block_flags(var.self) : Bitset();
if (flags.get(DecorationPerPrimitiveEXT) || has_decoration(var_id, DecorationPerPrimitiveEXT))
var_id = id_per_primitive;
else