cargo: Bump rustc to 1.89 (#36818)

Update Rustc to 1.89.

Reviewable by commit.

Leftover work:
- #37330 
- #38777

---------

Signed-off-by: sagudev <16504129+sagudev@users.noreply.github.com>
Co-authored-by: sagudev <16504129+sagudev@users.noreply.github.com>
This commit is contained in:
webbeef 2025-08-19 04:07:53 -07:00 committed by GitHub
parent 8587536755
commit 3225d19907
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
126 changed files with 408 additions and 610 deletions

View file

@ -378,16 +378,14 @@ namespace_id! {OffscreenCanvasId, OffscreenCanvasIndex, "OffscreenCanvas"}
// We provide ids just for unit testing.
pub const TEST_NAMESPACE: PipelineNamespaceId = PipelineNamespaceId(1234);
#[allow(unsafe_code)]
pub const TEST_PIPELINE_INDEX: Index<PipelineIndex> =
unsafe { Index(NonZeroU32::new_unchecked(5678), PhantomData) };
Index(NonZeroU32::new(5678).unwrap(), PhantomData);
pub const TEST_PIPELINE_ID: PipelineId = PipelineId {
namespace_id: TEST_NAMESPACE,
index: TEST_PIPELINE_INDEX,
};
#[allow(unsafe_code)]
pub const TEST_BROWSING_CONTEXT_INDEX: Index<BrowsingContextIndex> =
unsafe { Index(NonZeroU32::new_unchecked(8765), PhantomData) };
Index(NonZeroU32::new(8765).unwrap(), PhantomData);
pub const TEST_BROWSING_CONTEXT_ID: BrowsingContextId = BrowsingContextId {
namespace_id: TEST_NAMESPACE,
index: TEST_BROWSING_CONTEXT_INDEX,

View file

@ -98,7 +98,7 @@ impl BluetoothScanfilterSequence {
self.0.iter().any(BluetoothScanfilter::is_empty_or_invalid)
}
pub fn iter(&self) -> Iter<BluetoothScanfilter> {
pub fn iter(&self) -> Iter<'_, BluetoothScanfilter> {
self.0.iter()
}

View file

@ -769,7 +769,7 @@ pub struct ActiveUniformInfo {
}
impl ActiveUniformInfo {
pub fn name(&self) -> Cow<str> {
pub fn name(&self) -> Cow<'_, str> {
if self.size.is_some() {
let mut name = String::from(&*self.base_name);
name.push_str("[0]");

View file

@ -350,7 +350,7 @@ impl CrossProcessCompositorApi {
/// This trait is used to notify lock/unlock messages and get the
/// required info that WR needs.
pub trait WebrenderExternalImageApi {
fn lock(&mut self, id: u64) -> (ExternalImageSource, UntypedSize2D<i32>);
fn lock(&mut self, id: u64) -> (ExternalImageSource<'_>, UntypedSize2D<i32>);
fn unlock(&mut self, id: u64);
}
@ -433,7 +433,7 @@ impl ExternalImageHandler for WebrenderExternalImageHandlers {
/// image content.
/// The WR client should not change the image content until the
/// unlock() call.
fn lock(&mut self, key: ExternalImageId, _channel_index: u8) -> ExternalImage {
fn lock(&mut self, key: ExternalImageId, _channel_index: u8) -> ExternalImage<'_> {
let external_images = self.external_images.lock().unwrap();
let handler_type = external_images
.get(&key)

View file

@ -466,7 +466,7 @@ impl WindowRenderingContext {
Ok(())
}
pub fn surfman_details(&self) -> (RefMut<Device>, RefMut<Context>) {
pub fn surfman_details(&self) -> (RefMut<'_, Device>, RefMut<'_, Context>) {
(
self.surfman_context.device.borrow_mut(),
self.surfman_context.context.borrow_mut(),

View file

@ -291,7 +291,7 @@ pub trait ThreadSafeLayoutElement<'dom>:
fn get_attr_enum(&self, namespace: &Namespace, name: &LocalName) -> Option<&AttrValue>;
fn style_data(&self) -> AtomicRef<ElementData>;
fn style_data(&self) -> AtomicRef<'_, ElementData>;
fn pseudo_element_chain(&self) -> PseudoElementChain;

View file

@ -70,6 +70,7 @@ pub enum RenderCommand {
ExecuteBundles(Vec<RenderBundleId>),
}
#[allow(clippy::result_large_err)]
pub fn apply_render_command(
global: &Global,
pass: &mut RenderPass,