VkSwapchain: Remove useless drop_swapchain
Some checks failed
Build legacy Nix package on Ubuntu / build (push) Failing after 0s

This commit is contained in:
Florian RICHER 2024-11-15 22:49:05 +01:00
parent 5272bf14e8
commit 21195b57e6
Signed by: florian.richer
GPG key ID: C73D37CBED7BFC77

View file

@ -159,18 +159,14 @@ impl VkSwapchain {
.clipped(true)
.image_array_layers(1)
}
}
fn drop_swapchain(&mut self) {
impl Drop for VkSwapchain {
fn drop(&mut self) {
if let Some(swapchain) = self.swapchain {
unsafe { self.device.swapchain_loader.destroy_swapchain(swapchain, None); }
self.swapchain = None;
log::debug!(target: LOG_TARGET, "Swapchain destroyed ({swapchain:?})");
}
}
}
impl Drop for VkSwapchain {
fn drop(&mut self) {
self.drop_swapchain()
}
}