Fixed compilation with MSVC.

This commit is contained in:
2024-06-26 10:04:01 +02:00
parent c5a9d960e8
commit 99821bf2f5
4 changed files with 10 additions and 6 deletions

View File

@@ -101,7 +101,7 @@ void addShaderAttribute(std::vector<ShaderAttribute>& attributes, ShaderAttribut
ShaderVariableStructType::ShaderVariableStructType() {} // NOLINT(modernize-use-equals-default)
ShaderVariableStructType::~ShaderVariableStructType() {} // NOLINT(modernize-use-equals-default)
void ShaderMeta::extendPushConstant(ShaderPushConstantBlock pushConstantBlock_, ShaderTypeBits stages)
void ShaderMeta::extendPushConstant(ShaderPushConstantBlock pushConstantBlock_, ShaderTypeBits pushConstantStages_)
{
if (pushConstantBlock_.type.baseType == ShaderVariableBaseType::NONE) {
return;
@@ -109,14 +109,14 @@ void ShaderMeta::extendPushConstant(ShaderPushConstantBlock pushConstantBlock_,
if (pushConstantBlock.type.baseType == ShaderVariableBaseType::NONE)
{
pushConstantBlock = std::move(pushConstantBlock_);
pushConstantStages = stages;
pushConstantStages = pushConstantStages_;
return;
}
// now comes the actual merging
assert(pushConstantBlock.type.baseType == ShaderVariableBaseType::STRUCT);
assert(pushConstantBlock_.type.baseType == ShaderVariableBaseType::STRUCT);
assert(stages);
assert(pushConstantStages_);
for (ShaderVariableStructMember& member : pushConstantBlock_.type.struct_.members)
{
@@ -158,7 +158,7 @@ void ShaderMeta::extendPushConstant(ShaderPushConstantBlock pushConstantBlock_,
pushConstantBlock.type.struct_.members.insert(it, std::move(member));
}
pushConstantStages |= stages;
pushConstantStages |= pushConstantStages_;
}
void ShaderMeta::addInputAttribute(ShaderAttribute attribute)