Skip to content

Commit

Permalink
Bumped up Rust and dependency versions.
Browse files Browse the repository at this point in the history
Use new Rust 1.77 C-string literals.
Addressed Clippy warnings.
  • Loading branch information
zlogic committed Apr 4, 2024
1 parent 18b8e95 commit c706fd6
Show file tree
Hide file tree
Showing 5 changed files with 79 additions and 75 deletions.
136 changes: 70 additions & 66 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 3 additions & 3 deletions Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,16 +1,16 @@
[package]
name = "cybervision"
version = "0.19.0"
version = "0.19.1"
edition = "2021"
authors = ["Dmitry Zolotukhin <[email protected]>"]
repository = "https://github.com/zlogic/cybervision"
license = "Apache-2.0"
rust-version = "1.75"
rust-version = "1.77"

# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html

[dependencies]
image = { version = "0.24", default_features = false, features = ["png", "jpeg", "tiff", "jpeg_rayon"] }
image = { version = "0.25", default_features = false, features = ["png", "jpeg", "tiff", "rayon"] }
indicatif = { version = "0.17", default_features = false }
rayon = "*"
rand = { version = "0.8", default_features = false, features = ["std", "std_rng", "small_rng"] }
Expand Down
4 changes: 2 additions & 2 deletions src/correlation/gpu/metal.rs
Original file line number Diff line number Diff line change
Expand Up @@ -429,10 +429,10 @@ impl super::Device for Device {
impl Drop for DeviceContext {
fn drop(&mut self) {
autoreleasepool(|| {
self.device.as_mut().map(|device| {
if let Some(device) = self.device.as_mut() {
device.pipelines.clear();
device.buffers = None;
});
};
self.device = None;
});
}
Expand Down
6 changes: 3 additions & 3 deletions src/correlation/gpu/vulkan.rs
Original file line number Diff line number Diff line change
Expand Up @@ -403,8 +403,8 @@ impl Device {
}

unsafe fn init_vk(entry: &ash::Entry) -> VkResult<ash::Instance> {
let app_name = CStr::from_bytes_with_nul_unchecked(b"Cybervision\0");
let engine_name = CStr::from_bytes_with_nul_unchecked(b"cybervision\0");
let app_name = c"Cybervision";
let engine_name = c"cybervision";
let appinfo = vk::ApplicationInfo::builder()
.application_name(app_name)
.application_version(0)
Expand Down Expand Up @@ -791,7 +791,7 @@ impl Device {
) -> Result<HashMap<ShaderModuleType, ShaderPipeline>, Box<dyn error::Error>> {
let shader_modules = Device::load_shaders(device)?;

let main_module_name = CStr::from_bytes_with_nul_unchecked(b"main\0");
let main_module_name = c"main";

let pipeline_create_info = shader_modules
.iter()
Expand Down
Loading

0 comments on commit c706fd6

Please sign in to comment.