From f4d7b3e3b1e42c86f8624d62d43a165d5ac16c7b Mon Sep 17 00:00:00 2001 From: Piotr Osiewicz <24362066+osiewicz@users.noreply.github.com> Date: Fri, 9 Feb 2024 09:45:39 +0100 Subject: [PATCH] chore: Bump Rust version to 1.76 (#7592) Release Notes: - N/A --- Dockerfile | 2 +- crates/gpui/src/key_dispatch.rs | 2 +- crates/gpui/src/keymap.rs | 4 ++-- crates/gpui/src/window.rs | 2 +- rust-toolchain.toml | 2 +- 5 files changed, 6 insertions(+), 6 deletions(-) diff --git a/Dockerfile b/Dockerfile index b4d7b10d37..55ab7fe67b 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,6 +1,6 @@ # syntax = docker/dockerfile:1.2 -FROM rust:1.75-bullseye as builder +FROM rust:1.76-bullseye as builder WORKDIR app COPY . . diff --git a/crates/gpui/src/key_dispatch.rs b/crates/gpui/src/key_dispatch.rs index 8f9eb16a62..af56f4344f 100644 --- a/crates/gpui/src/key_dispatch.rs +++ b/crates/gpui/src/key_dispatch.rs @@ -304,7 +304,7 @@ impl DispatchTree { pub fn bindings_for_action( &self, action: &dyn Action, - context_stack: &Vec, + context_stack: &[KeyContext], ) -> Vec { let keymap = self.keymap.borrow(); keymap diff --git a/crates/gpui/src/keymap.rs b/crates/gpui/src/keymap.rs index e2a6bdfc4b..d6b84f10e6 100644 --- a/crates/gpui/src/keymap.rs +++ b/crates/gpui/src/keymap.rs @@ -71,7 +71,7 @@ impl Keymap { } /// Iterate over all bindings, in the order they were added. - pub fn bindings(&self) -> impl Iterator + DoubleEndedIterator { + pub fn bindings(&self) -> impl DoubleEndedIterator { self.bindings.iter() } @@ -79,7 +79,7 @@ impl Keymap { pub fn bindings_for_action<'a>( &'a self, action: &'a dyn Action, - ) -> impl 'a + Iterator + DoubleEndedIterator { + ) -> impl 'a + DoubleEndedIterator { let action_id = action.type_id(); self.binding_indices_by_action_id .get(&action_id) diff --git a/crates/gpui/src/window.rs b/crates/gpui/src/window.rs index e81cd12c69..8393da1da0 100644 --- a/crates/gpui/src/window.rs +++ b/crates/gpui/src/window.rs @@ -1547,7 +1547,7 @@ impl<'a> WindowContext<'a> { let Some(node_id) = dispatch_tree.focusable_node_id(focus_handle.id) else { return vec![]; }; - let context_stack = dispatch_tree + let context_stack: Vec<_> = dispatch_tree .dispatch_path(node_id) .into_iter() .filter_map(|node_id| dispatch_tree.node(node_id).context.clone()) diff --git a/rust-toolchain.toml b/rust-toolchain.toml index cda3826601..f71bbee6be 100644 --- a/rust-toolchain.toml +++ b/rust-toolchain.toml @@ -1,5 +1,5 @@ [toolchain] -channel = "1.75" +channel = "1.76" profile = "minimal" components = [ "rustfmt", "clippy" ] targets = [ "x86_64-apple-darwin", "aarch64-apple-darwin", "x86_64-unknown-linux-gnu", "wasm32-wasi" ]