From 1ab31d0cddc068d66946c4b7e76adec83a1d2752 Mon Sep 17 00:00:00 2001 From: Miles Johnson Date: Thu, 28 Nov 2024 14:21:45 -0800 Subject: [PATCH 1/2] Update rust. --- crates/cli/src/commands/outdated.rs | 2 +- crates/cli/src/commands/status.rs | 2 +- crates/cli/src/main_shim.rs | 1 + crates/cli/src/printer.rs | 6 +++--- rust-toolchain.toml | 2 +- 5 files changed, 7 insertions(+), 6 deletions(-) diff --git a/crates/cli/src/commands/outdated.rs b/crates/cli/src/commands/outdated.rs index 683105cb4..a5df6c48a 100644 --- a/crates/cli/src/commands/outdated.rs +++ b/crates/cli/src/commands/outdated.rs @@ -72,7 +72,7 @@ pub async fn outdated(session: ProtoSession, args: OutdatedArgs) -> AppResult { for file in manager.files.iter().rev() { if !file.exists || !env.config_mode.includes_global() && file.global - || env.config_mode.only_local() && !file.path.parent().is_some_and(|p| p == env.cwd) + || env.config_mode.only_local() && file.path.parent().is_none_or(|p| p != env.cwd) { continue; } diff --git a/crates/cli/src/commands/status.rs b/crates/cli/src/commands/status.rs index a86b94ad4..3d2367b6a 100644 --- a/crates/cli/src/commands/status.rs +++ b/crates/cli/src/commands/status.rs @@ -42,7 +42,7 @@ fn find_versions_in_configs( if !file.exists || !env.config_mode.includes_global() && file.global || env.config_mode.only_local() - && !file.path.parent().is_some_and(|p| p == session.env.cwd) + && file.path.parent().is_none_or(|p| p != session.env.cwd) { continue; } diff --git a/crates/cli/src/main_shim.rs b/crates/cli/src/main_shim.rs index aef390aed..69b659fdd 100644 --- a/crates/cli/src/main_shim.rs +++ b/crates/cli/src/main_shim.rs @@ -15,6 +15,7 @@ static mut DEBUG: Option = None; // We don't want to pull the entire `tracing` or `log` crates // into this binary, as we want it to be super lean. So we have // this very rudimentary logging system. +#[allow(static_mut_refs)] fn debug(op: impl FnOnce() -> String) { unsafe { if DEBUG.is_none() { diff --git a/crates/cli/src/printer.rs b/crates/cli/src/printer.rs index 90402a199..64a8b9e85 100644 --- a/crates/cli/src/printer.rs +++ b/crates/cli/src/printer.rs @@ -7,10 +7,10 @@ pub struct Printer<'std> { depth: u8, } -unsafe impl<'std> Send for Printer<'std> {} -unsafe impl<'std> Sync for Printer<'std> {} +unsafe impl Send for Printer<'_> {} +unsafe impl Sync for Printer<'_> {} -impl<'std> Printer<'std> { +impl Printer<'_> { pub fn new() -> Self { let stdout = std::io::stdout(); let buffer = BufWriter::new(stdout.lock()); diff --git a/rust-toolchain.toml b/rust-toolchain.toml index 1a07338aa..80f03dfe1 100644 --- a/rust-toolchain.toml +++ b/rust-toolchain.toml @@ -1,3 +1,3 @@ [toolchain] profile = "default" -channel = "1.82.0" +channel = "1.83.0" From b6498cb686dc4f1b7fe37d5339e16b64bbf89511 Mon Sep 17 00:00:00 2001 From: Miles Johnson Date: Thu, 28 Nov 2024 14:22:10 -0800 Subject: [PATCH 2/2] Update changelog. --- CHANGELOG.md | 1 + 1 file changed, 1 insertion(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 6d5195e0d..7834b5826 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -29,6 +29,7 @@ - Updated identifiers, versions, and locators to use [compact strings](https://crates.io/crates/compact_str). - Updated wasmtime to v26 (from v23). +- Updated Rust to v1.83. ## 0.42.2