mirror of
https://github.com/KhronosGroup/Vulkan-Hpp
synced 2024-11-08 13:40:08 +00:00
replace memcpy in generated copy and assignment operators of VkStructures by reinterpreted assignments. (#348)
Fixes #342
This commit is contained in:
parent
837a5d6a23
commit
89a56017a8
@ -3765,12 +3765,12 @@ ${initializers} {${copyOps}}
|
||||
${subStructConstructor}
|
||||
${name}( Vk${name} const & rhs )
|
||||
{
|
||||
memcpy( this, &rhs, sizeof( ${name} ) );
|
||||
*reinterpret_cast<Vk${name}*>(this) = rhs;
|
||||
}
|
||||
|
||||
${name}& operator=( Vk${name} const & rhs )
|
||||
{
|
||||
memcpy( this, &rhs, sizeof( ${name} ) );
|
||||
*reinterpret_cast<Vk${name}*>(this) = rhs;
|
||||
return *this;
|
||||
}
|
||||
)";
|
||||
|
1348
vulkan/vulkan.hpp
1348
vulkan/vulkan.hpp
File diff suppressed because it is too large
Load Diff
Loading…
Reference in New Issue
Block a user