From d296d9f56858f1c31fefe22871d58c8247361446 Mon Sep 17 00:00:00 2001 From: coyaSONG <66289470+coyaSONG@users.noreply.github.com> Date: Sat, 18 Jul 2026 12:34:43 +0900 Subject: [PATCH 1/2] Highlight Rust async and await keywords --- assets/patches/Rust.sublime-syntax.patch | 3 +++ tests/syntax-tests/highlighted/Rust/output.rs | 4 ++++ tests/syntax-tests/source/Rust/output.rs | 4 ++++ 3 files changed, 11 insertions(+) diff --git a/assets/patches/Rust.sublime-syntax.patch b/assets/patches/Rust.sublime-syntax.patch index 3bd745e28f..6bac81cdf0 100644 --- a/assets/patches/Rust.sublime-syntax.patch +++ b/assets/patches/Rust.sublime-syntax.patch @@ -2,6 +2,9 @@ diff --git syntaxes/01_Packages/Rust/Rust.sublime-syntax syntaxes/01_Packages/Ru index 3c354486..24727a4e 100644 --- syntaxes/01_Packages/Rust/Rust.sublime-syntax +++ syntaxes/01_Packages/Rust/Rust.sublime-syntax +@@ -139 +139 @@ contexts: +- - match: \b(break|else|for|if|loop|match|while|continue)\b ++ - match: \b(async|await|break|else|for|if|loop|match|while|continue)\b @@ -907,6 +907,8 @@ contexts: - include: type-any-identifier - match: ':' diff --git a/tests/syntax-tests/highlighted/Rust/output.rs b/tests/syntax-tests/highlighted/Rust/output.rs index 14755cf6d0..7394989f41 100644 --- a/tests/syntax-tests/highlighted/Rust/output.rs +++ b/tests/syntax-tests/highlighted/Rust/output.rs @@ -159,3 +159,7 @@  }  } } + +async fn foo() { + async_foo().await.await.await; +} diff --git a/tests/syntax-tests/source/Rust/output.rs b/tests/syntax-tests/source/Rust/output.rs index e7d59d6707..027fca98a3 100644 --- a/tests/syntax-tests/source/Rust/output.rs +++ b/tests/syntax-tests/source/Rust/output.rs @@ -159,3 +159,7 @@ impl Drop for OutputType { } } } + +async fn foo() { + async_foo().await.await.await; +} From 2a2a2999dd557a7e6951f961e469c84e929f18db Mon Sep 17 00:00:00 2001 From: coyaSONG <66289470+coyaSONG@users.noreply.github.com> Date: Sat, 18 Jul 2026 12:36:53 +0900 Subject: [PATCH 2/2] Add changelog entry for PR 3849 --- CHANGELOG.md | 1 + 1 file changed, 1 insertion(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 0e2fc2161d..28bf79c5b4 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -61,6 +61,7 @@ ## Syntaxes +- Highlight Rust `async` and `await` as keywords, see #3849 (@coyaSONG) - Add shebang-based detection for Tcl (`tclsh`, `wish`) and Expect (`expect`) scripts, see #3647 (@mvanhorn) - Change the URL of Zig submodule from GitHub to Codeberg, see #3519 (@sorairolake) - Don't color strings inside CSV files, to make it easier to tell which column they belong to, see #3521 (@keith-hall)