chore: Fix up warnings from cargo +beta check. (#7453)

With upcoming release of 1.76 I did a check of current +beta (which
seems to already be at 1.77). These would cause CI pipeline failures
once 1.77 is out.

Release Notes:

- N/A
This commit is contained in:
Piotr Osiewicz 2024-02-06 20:36:02 +01:00 committed by GitHub
parent 792c832205
commit 70e7ea365c
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 7 additions and 5 deletions

View file

@ -11,7 +11,12 @@ use objc::{
}; };
use parking::{Parker, Unparker}; use parking::{Parker, Unparker};
use parking_lot::Mutex; use parking_lot::Mutex;
use std::{ffi::c_void, ptr::NonNull, sync::Arc, time::Duration}; use std::{
ffi::c_void,
ptr::{addr_of, NonNull},
sync::Arc,
time::Duration,
};
/// All items in the generated file are marked as pub, so we're gonna wrap it in a separate mod to prevent /// All items in the generated file are marked as pub, so we're gonna wrap it in a separate mod to prevent
/// these pub items from leaking into public API. /// these pub items from leaking into public API.
@ -21,7 +26,7 @@ pub(crate) mod dispatch_sys {
use dispatch_sys::*; use dispatch_sys::*;
pub(crate) fn dispatch_get_main_queue() -> dispatch_queue_t { pub(crate) fn dispatch_get_main_queue() -> dispatch_queue_t {
unsafe { &_dispatch_main_q as *const _ as dispatch_queue_t } unsafe { addr_of!(_dispatch_main_q) as *const _ as dispatch_queue_t }
} }
pub(crate) struct MacDispatcher { pub(crate) struct MacDispatcher {

View file

@ -863,6 +863,3 @@ impl PathVertex<Pixels> {
} }
} }
} }
#[derive(Copy, Clone, Debug)]
pub(crate) struct AtlasId(pub(crate) usize);