about summary refs log tree commit diff
path: root/src/tools/rust-analyzer/xtask
diff options
context:
space:
mode:
authorbors <bors@rust-lang.org>2024-06-30 12:11:12 +0000
committerbors <bors@rust-lang.org>2024-06-30 12:11:12 +0000
commit079ee28362b640105aa93483975e3f6797f43014 (patch)
treec0031cb4525d60ff7e15b5aaa04f1b6b32f7f38d /src/tools/rust-analyzer/xtask
parentacdfab645ffb48ce1735da9a43af3ed182dcaa0b (diff)
parenteb72a9e2fd11632b9c7001a108458d92f7ec1e8c (diff)
downloadrust-079ee28362b640105aa93483975e3f6797f43014.tar.gz
rust-079ee28362b640105aa93483975e3f6797f43014.zip
Auto merge of #17518 - Veykril:expr-scopes-mac, r=Veykril
fix: Fix expression scope calculation when within macro expansions
Diffstat (limited to 'src/tools/rust-analyzer/xtask')
-rw-r--r--src/tools/rust-analyzer/xtask/src/codegen/diagnostics_docs.rs2
-rw-r--r--src/tools/rust-analyzer/xtask/src/release.rs3
2 files changed, 2 insertions, 3 deletions
diff --git a/src/tools/rust-analyzer/xtask/src/codegen/diagnostics_docs.rs b/src/tools/rust-analyzer/xtask/src/codegen/diagnostics_docs.rs
index cf30531e7f9..dcc9c76a509 100644
--- a/src/tools/rust-analyzer/xtask/src/codegen/diagnostics_docs.rs
+++ b/src/tools/rust-analyzer/xtask/src/codegen/diagnostics_docs.rs
@@ -63,7 +63,7 @@ fn is_valid_diagnostic_name(diagnostic: &str) -> Result<(), String> {
     if diagnostic.chars().any(|c| c.is_ascii_uppercase()) {
         return Err("Diagnostic names can't contain uppercase symbols".into());
     }
-    if diagnostic.chars().any(|c| !c.is_ascii()) {
+    if !diagnostic.is_ascii() {
         return Err("Diagnostic can't contain non-ASCII symbols".into());
     }
 
diff --git a/src/tools/rust-analyzer/xtask/src/release.rs b/src/tools/rust-analyzer/xtask/src/release.rs
index 5699053a23d..b936876b528 100644
--- a/src/tools/rust-analyzer/xtask/src/release.rs
+++ b/src/tools/rust-analyzer/xtask/src/release.rs
@@ -119,12 +119,11 @@ impl flags::RustcPull {
         // Fetch given rustc commit.
         cmd!(sh, "git fetch http://localhost:{JOSH_PORT}/rust-lang/rust.git@{commit}{JOSH_FILTER}.git")
             .run()
-            .map_err(|e| {
+            .inspect_err(|_| {
                 // Try to un-do the previous `git commit`, to leave the repo in the state we found it it.
                 cmd!(sh, "git reset --hard HEAD^")
                     .run()
                     .expect("FAILED to clean up again after failed `git fetch`, sorry for that");
-                e
             })
             .context("FAILED to fetch new commits, something went wrong (committing the rust-version file has been undone)")?;