From 84a4c9c3a7edbd1cd6e27809d5ff84a8a11c7a2a Mon Sep 17 00:00:00 2001 From: "alexey.lysiuk" Date: Mon, 4 Mar 2019 16:18:37 +0200 Subject: [PATCH] - reorderer member initialization in Vulkan objects This is needed to prevent compilation warnings spam with GCC and Clang While the warning itself is useful, in this case it's rather pointless and annoying --- src/rendering/vulkan/system/vk_objects.h | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/rendering/vulkan/system/vk_objects.h b/src/rendering/vulkan/system/vk_objects.h index b5de0c748..bcf54b969 100644 --- a/src/rendering/vulkan/system/vk_objects.h +++ b/src/rendering/vulkan/system/vk_objects.h @@ -804,7 +804,7 @@ inline void VulkanCommandBuffer::executeCommands(uint32_t commandBufferCount, co ///////////////////////////////////////////////////////////////////////////// -inline VulkanShader::VulkanShader(VulkanDevice *device, VkShaderModule module) : device(device), module(module) +inline VulkanShader::VulkanShader(VulkanDevice *device, VkShaderModule module) : module(module), device(device) { } @@ -875,7 +875,7 @@ inline VulkanFramebuffer::~VulkanFramebuffer() ///////////////////////////////////////////////////////////////////////////// -inline VulkanImage::VulkanImage(VulkanDevice *device, VkImage image, VmaAllocation allocation, int width, int height, int mipLevels) : device(device), image(image), allocation(allocation), width(width), height(height), mipLevels(mipLevels) +inline VulkanImage::VulkanImage(VulkanDevice *device, VkImage image, VmaAllocation allocation, int width, int height, int mipLevels) : image(image), width(width), height(height), mipLevels(mipLevels), device(device), allocation(allocation) { } @@ -898,7 +898,7 @@ inline void VulkanImage::Unmap() ///////////////////////////////////////////////////////////////////////////// -inline VulkanImageView::VulkanImageView(VulkanDevice *device, VkImageView view) : device(device), view(view) +inline VulkanImageView::VulkanImageView(VulkanDevice *device, VkImageView view) : view(view), device(device) { } @@ -909,7 +909,7 @@ inline VulkanImageView::~VulkanImageView() ///////////////////////////////////////////////////////////////////////////// -inline VulkanSampler::VulkanSampler(VulkanDevice *device, VkSampler sampler) : device(device), sampler(sampler) +inline VulkanSampler::VulkanSampler(VulkanDevice *device, VkSampler sampler) : sampler(sampler), device(device) { }