From 460009d2955a062db015494a45917acb91f98bae Mon Sep 17 00:00:00 2001 From: deathaxe Date: Mon, 26 Aug 2024 20:56:51 +0200 Subject: [PATCH] Add `await` keyword --- CoffeeScript.sublime-syntax | 2 +- tests/syntax_test_scope.coffee | 5 +++++ 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/CoffeeScript.sublime-syntax b/CoffeeScript.sublime-syntax index 3320bba..0d80125 100644 --- a/CoffeeScript.sublime-syntax +++ b/CoffeeScript.sublime-syntax @@ -314,7 +314,7 @@ contexts: - match: while(?!\s*:)\b scope: keyword.control.loop.while.coffee # flow - - match: (?:break|continue|return|throw|yield(?:\s+from)?)(?!\s*:)\b + - match: (?:await|break|continue|return|throw|yield(?:\s+from)?)(?!\s*:)\b scope: keyword.control.flow.coffee # other - match: (?:debugger\b|\\) diff --git a/tests/syntax_test_scope.coffee b/tests/syntax_test_scope.coffee index 4436649..5d700a8 100644 --- a/tests/syntax_test_scope.coffee +++ b/tests/syntax_test_scope.coffee @@ -236,6 +236,11 @@ class App.Router extends Snakeskin.Router # ^^^^^^^^^^ keyword.control.flow.coffee # ^^^^ variable.other.readwrite.instance.coffee + await return @foo; +# ^^^^^ keyword.control.flow.coffee +# ^^^^^^ keyword.control.flow.coffee +# ^^^^ variable.other.readwrite.instance.coffee + ###[ OPERATORS ]############################################################### as