From afc2e3732c4862c3b7f911b77f03c219ec3c61bb Mon Sep 17 00:00:00 2001 From: Pierre Krieger Date: Tue, 4 Jul 2017 14:00:53 +0200 Subject: [PATCH] Fix warnings --- vulkano/src/buffer/cpu_access.rs | 4 ---- vulkano/src/buffer/cpu_pool.rs | 1 - vulkano/src/command_buffer/validity/update_buffer.rs | 4 ++-- vulkano/src/image/attachment.rs | 1 - vulkano/src/image/immutable.rs | 2 -- vulkano/src/image/storage.rs | 2 -- vulkano/src/image/swapchain.rs | 2 -- 7 files changed, 2 insertions(+), 14 deletions(-) diff --git a/vulkano/src/buffer/cpu_access.rs b/vulkano/src/buffer/cpu_access.rs index e480ab6c..5e5d1e9a 100644 --- a/vulkano/src/buffer/cpu_access.rs +++ b/vulkano/src/buffer/cpu_access.rs @@ -30,7 +30,6 @@ use std::sync::Arc; use std::sync::RwLock; use std::sync::RwLockReadGuard; use std::sync::RwLockWriteGuard; -use std::sync::TryLockError; use buffer::BufferUsage; use buffer::sys::BufferCreationError; @@ -48,11 +47,8 @@ use memory::CpuAccess as MemCpuAccess; use memory::pool::AllocLayout; use memory::pool::MemoryPool; use memory::pool::MemoryPoolAlloc; -use memory::pool::StdMemoryPool; use memory::pool::StdMemoryPoolAlloc; use sync::AccessError; -use sync::AccessFlagBits; -use sync::PipelineStages; use sync::Sharing; use OomError; diff --git a/vulkano/src/buffer/cpu_pool.rs b/vulkano/src/buffer/cpu_pool.rs index b72ab21a..c85366f0 100644 --- a/vulkano/src/buffer/cpu_pool.rs +++ b/vulkano/src/buffer/cpu_pool.rs @@ -14,7 +14,6 @@ use std::mem; use std::sync::Arc; use std::sync::Mutex; use std::sync::MutexGuard; -use std::sync::atomic::AtomicBool; use std::sync::atomic::AtomicUsize; use std::sync::atomic::Ordering; diff --git a/vulkano/src/command_buffer/validity/update_buffer.rs b/vulkano/src/command_buffer/validity/update_buffer.rs index 6c07b526..b60f90e2 100644 --- a/vulkano/src/command_buffer/validity/update_buffer.rs +++ b/vulkano/src/command_buffer/validity/update_buffer.rs @@ -124,8 +124,8 @@ mod tests { let (device, queue) = gfx_dev_and_queue!(); let buffer = CpuAccessibleBuffer::from_iter(device.clone(), BufferUsage::transfer_destination(), iter::once(queue.family()), - 0 .. 100000).unwrap(); - let data = (0 .. 65536).collect::>(); + (0 .. 100000).map(|_| 0)).unwrap(); + let data = (0 .. 65536).map(|_| 0).collect::>(); match check_update_buffer(&device, &buffer, &data[..]) { Ok(_) => (), diff --git a/vulkano/src/image/attachment.rs b/vulkano/src/image/attachment.rs index 1236e08b..1ef0e6c7 100644 --- a/vulkano/src/image/attachment.rs +++ b/vulkano/src/image/attachment.rs @@ -9,7 +9,6 @@ use std::iter::Empty; use std::sync::Arc; -use std::sync::atomic::AtomicBool; use std::sync::atomic::AtomicUsize; use std::sync::atomic::Ordering; diff --git a/vulkano/src/image/immutable.rs b/vulkano/src/image/immutable.rs index d96eb6f8..ba4d5dc3 100644 --- a/vulkano/src/image/immutable.rs +++ b/vulkano/src/image/immutable.rs @@ -12,10 +12,8 @@ use std::sync::Arc; use device::Device; use device::Queue; -use format::Format; use format::FormatDesc; use image::Dimensions; -use image::ImageDimensions; use image::ImageInner; use image::ImageLayout; use image::ImageUsage; diff --git a/vulkano/src/image/storage.rs b/vulkano/src/image/storage.rs index a75cdfc3..124ef642 100644 --- a/vulkano/src/image/storage.rs +++ b/vulkano/src/image/storage.rs @@ -16,11 +16,9 @@ use std::sync::atomic::Ordering; use device::Device; use device::Queue; use format::ClearValue; -use format::Format; use format::FormatDesc; use format::FormatTy; use image::Dimensions; -use image::ImageDimensions; use image::ImageInner; use image::ImageLayout; use image::ImageUsage; diff --git a/vulkano/src/image/swapchain.rs b/vulkano/src/image/swapchain.rs index 5cb76805..8c412ae4 100644 --- a/vulkano/src/image/swapchain.rs +++ b/vulkano/src/image/swapchain.rs @@ -14,11 +14,9 @@ use format::ClearValue; use format::Format; use format::FormatDesc; use image::Dimensions; -use image::ImageDimensions; use image::ImageInner; use image::ImageLayout; use image::ViewType; -use image::sys::UnsafeImage; use image::sys::UnsafeImageView; use image::traits::ImageAccess; use image::traits::ImageClearValue;