mirror of
https://github.com/KhronosGroup/Vulkan-Hpp.git
synced 2024-10-14 16:32:17 +00:00
Add missing const-qualifier in the static_cast in function T const & StructureChain::getFeatures2() const.
This commit is contained in:
parent
7abf60533a
commit
e159e685d4
@ -10435,7 +10435,7 @@ int main( int argc, char ** argv )
|
|||||||
template <typename T = typename std::tuple_element<0, std::tuple<ChainElements...>>::type, size_t Which = 0>
|
template <typename T = typename std::tuple_element<0, std::tuple<ChainElements...>>::type, size_t Which = 0>
|
||||||
T const & get() const VULKAN_HPP_NOEXCEPT
|
T const & get() const VULKAN_HPP_NOEXCEPT
|
||||||
{
|
{
|
||||||
return std::get<ChainElementIndex<0, T, Which, void, ChainElements...>::value>( static_cast<std::tuple<ChainElements...>&>( *this ) );
|
return std::get<ChainElementIndex<0, T, Which, void, ChainElements...>::value>( static_cast<std::tuple<ChainElements...> const &>( *this ) );
|
||||||
}
|
}
|
||||||
|
|
||||||
template <typename T0, typename T1, typename... Ts>
|
template <typename T0, typename T1, typename... Ts>
|
||||||
|
@ -55,7 +55,9 @@ int main( int /*argc*/, char ** /*argv*/ )
|
|||||||
|
|
||||||
// some valid StructureChains
|
// some valid StructureChains
|
||||||
vk::StructureChain<vk::PhysicalDeviceProperties2> sc0;
|
vk::StructureChain<vk::PhysicalDeviceProperties2> sc0;
|
||||||
vk::StructureChain<vk::PhysicalDeviceProperties2, vk::PhysicalDeviceIDProperties> sc1;
|
const vk::StructureChain<vk::PhysicalDeviceProperties2, vk::PhysicalDeviceIDProperties> sc1;
|
||||||
|
auto pdp = sc1.get<vk::PhysicalDeviceProperties2>();
|
||||||
|
unused( pdp );
|
||||||
vk::StructureChain<vk::PhysicalDeviceProperties2, vk::PhysicalDeviceMaintenance3Properties> sc2;
|
vk::StructureChain<vk::PhysicalDeviceProperties2, vk::PhysicalDeviceMaintenance3Properties> sc2;
|
||||||
vk::StructureChain<vk::PhysicalDeviceProperties2, vk::PhysicalDevicePushDescriptorPropertiesKHR> sc3;
|
vk::StructureChain<vk::PhysicalDeviceProperties2, vk::PhysicalDevicePushDescriptorPropertiesKHR> sc3;
|
||||||
vk::StructureChain<vk::PhysicalDeviceProperties2,
|
vk::StructureChain<vk::PhysicalDeviceProperties2,
|
||||||
|
@ -978,7 +978,7 @@ namespace VULKAN_HPP_NAMESPACE
|
|||||||
T const & get() const VULKAN_HPP_NOEXCEPT
|
T const & get() const VULKAN_HPP_NOEXCEPT
|
||||||
{
|
{
|
||||||
return std::get<ChainElementIndex<0, T, Which, void, ChainElements...>::value>(
|
return std::get<ChainElementIndex<0, T, Which, void, ChainElements...>::value>(
|
||||||
static_cast<std::tuple<ChainElements...> &>( *this ) );
|
static_cast<std::tuple<ChainElements...> const &>( *this ) );
|
||||||
}
|
}
|
||||||
|
|
||||||
template <typename T0, typename T1, typename... Ts>
|
template <typename T0, typename T1, typename... Ts>
|
||||||
|
Loading…
Reference in New Issue
Block a user