diff --git a/src/device.rs b/src/device.rs index 11b5575..75061cc 100644 --- a/src/device.rs +++ b/src/device.rs @@ -8,8 +8,7 @@ use super::*; use block::{Block, ConcreteBlock}; -use foreign_types::ForeignType; -use objc::runtime::{Object, NO, YES}; +use objc::runtime::{NO, YES}; use std::{ffi::CStr, os::raw::c_char, path::Path, ptr}; diff --git a/src/lib.rs b/src/lib.rs index b79acf6..535c01d 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -20,13 +20,7 @@ pub extern crate foreign_types; #[macro_use] pub extern crate paste; -use std::{ - borrow::{Borrow, ToOwned}, - marker::PhantomData, - mem, - ops::Deref, - os::raw::c_void, -}; +use std::{borrow::Borrow, marker::PhantomData, mem, ops::Deref, os::raw::c_void}; use core_graphics_types::{base::CGFloat, geometry::CGSize}; use foreign_types::ForeignType; diff --git a/src/library.rs b/src/library.rs index 2c7d0c9..9f7d58c 100644 --- a/src/library.rs +++ b/src/library.rs @@ -7,11 +7,10 @@ use super::*; -use foreign_types::ForeignType; -use objc::runtime::{Object, BOOL, NO, YES}; +use objc::runtime::{BOOL, NO, YES}; use std::ffi::CStr; -use std::os::raw::{c_char, c_void}; +use std::os::raw::c_char; use std::ptr; /// Only available on (macos(10.12), ios(10.0) @@ -361,6 +360,10 @@ pub enum MTLLanguageVersion { V2_3 = 0x20003, /// available on macOS 12.0+, iOS 15.0+ V2_4 = 0x20004, + /// available on macOS 13.0+, iOS 16.0+ + V3_0 = 0x30000, + /// available on macOS 14.0+, iOS 17.0+ + V3_1 = 0x30001, } /// See diff --git a/src/mps.rs b/src/mps.rs index edd4936..f4c9fc8 100644 --- a/src/mps.rs +++ b/src/mps.rs @@ -7,9 +7,12 @@ use super::*; -use objc::runtime::{BOOL, YES}; +use objc::runtime::BOOL; -#[cfg_attr(feature = "link", link(name = "MetalPerformanceShaders", kind = "framework"))] +#[cfg_attr( + feature = "link", + link(name = "MetalPerformanceShaders", kind = "framework") +)] extern "C" { fn MPSSupportsMTLDevice(device: *const std::ffi::c_void) -> BOOL; } diff --git a/src/sync.rs b/src/sync.rs index 284fd90..c368048 100644 --- a/src/sync.rs +++ b/src/sync.rs @@ -7,7 +7,6 @@ use super::*; use block::{Block, RcBlock}; -use std::mem; use std::ptr; #[cfg(feature = "dispatch_queue")]