mirror of
https://github.com/KhronosGroup/Vulkan-Hpp.git
synced 2024-10-14 16:32:17 +00:00
Change all functions with ArrayProxy[NoTemporaries] as arguments to take by const & instead of by value.
This commit is contained in:
parent
4c576dee25
commit
8ae008dba8
@ -2798,7 +2798,7 @@ void VulkanHppGenerator::appendFunctionHeaderArgumentEnhancedVector( std::string
|
|||||||
// otherwise, use our ArrayProxy
|
// otherwise, use our ArrayProxy
|
||||||
bool isConst = ( param.type.prefix.find( "const" ) != std::string::npos );
|
bool isConst = ( param.type.prefix.find( "const" ) != std::string::npos );
|
||||||
str += optionalBegin + "ArrayProxy<" +
|
str += optionalBegin + "ArrayProxy<" +
|
||||||
( isTemplateParam ? ( isConst ? "const T" : "T" ) : stripPostfix( param.type.compose(), "*" ) ) + "> " +
|
( isTemplateParam ? ( isConst ? "const T" : "T" ) : stripPostfix( param.type.compose(), "*" ) ) + "> const &" +
|
||||||
optionalEnd + strippedParameterName;
|
optionalEnd + strippedParameterName;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -3834,7 +3834,7 @@ void VulkanHppGenerator::appendStructSetter( std::string & str
|
|||||||
}
|
}
|
||||||
|
|
||||||
static const std::string setArrayTemplate = R"(
|
static const std::string setArrayTemplate = R"(
|
||||||
${templateHeader}${structureName} & set${ArrayName}( VULKAN_HPP_NAMESPACE::ArrayProxyNoTemporaries<${memberType}> ${arrayName} ) VULKAN_HPP_NOEXCEPT
|
${templateHeader}${structureName} & set${ArrayName}( VULKAN_HPP_NAMESPACE::ArrayProxyNoTemporaries<${memberType}> const & ${arrayName} ) VULKAN_HPP_NOEXCEPT
|
||||||
{
|
{
|
||||||
${lenName} = ${lenValue};
|
${lenName} = ${lenValue};
|
||||||
${memberName} = ${arrayName}.data();
|
${memberName} = ${arrayName}.data();
|
||||||
|
File diff suppressed because it is too large
Load Diff
Loading…
Reference in New Issue
Block a user