Default Flags' copy functions

User-provided copy constructor and copy assignment operators prevent the class' ABI from being trivial.
This commit is contained in:
Krzysztof Kurek
2020-10-27 22:09:14 +01:00
parent cf92bfea25
commit 0eb17d3f86
2 changed files with 4 additions and 14 deletions

View File

@@ -679,7 +679,7 @@ namespace VULKAN_HPP_NAMESPACE
VULKAN_HPP_CONSTEXPR Flags( BitType bit ) VULKAN_HPP_NOEXCEPT : m_mask( static_cast<MaskType>( bit ) ) {}
VULKAN_HPP_CONSTEXPR Flags( Flags<BitType> const & rhs ) VULKAN_HPP_NOEXCEPT : m_mask( rhs.m_mask ) {}
VULKAN_HPP_CONSTEXPR Flags( Flags<BitType> const & rhs ) VULKAN_HPP_NOEXCEPT = default;
VULKAN_HPP_CONSTEXPR explicit Flags( MaskType flags ) VULKAN_HPP_NOEXCEPT : m_mask( flags ) {}
@@ -746,11 +746,7 @@ namespace VULKAN_HPP_NAMESPACE
}
// assignment operators
VULKAN_HPP_CONSTEXPR_14 Flags<BitType> & operator=( Flags<BitType> const & rhs ) VULKAN_HPP_NOEXCEPT
{
m_mask = rhs.m_mask;
return *this;
}
VULKAN_HPP_CONSTEXPR_14 Flags<BitType> & operator=( Flags<BitType> const & rhs ) VULKAN_HPP_NOEXCEPT = default;
VULKAN_HPP_CONSTEXPR_14 Flags<BitType> & operator|=( Flags<BitType> const & rhs ) VULKAN_HPP_NOEXCEPT
{