From 9ed3dc52e0d56f0f0fd721d7f10da5f935f56ef9 Mon Sep 17 00:00:00 2001 From: Jaakko Paju Date: Mon, 22 Jan 2024 20:51:56 +0200 Subject: Update Scala tree-sitter grammar (#9348) * Update Scala tree-sitter grammar * Support block comments Modify comment handling in textobjects and highlights to support new TS-scala node type 'block_comment'--- runtime/queries/scala/highlights.scm | 2 +- runtime/queries/scala/textobjects.scm | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) (limited to 'runtime/queries') diff --git a/runtime/queries/scala/highlights.scm b/runtime/queries/scala/highlights.scm index 67603fdd..40b230ec 100644 --- a/runtime/queries/scala/highlights.scm +++ b/runtime/queries/scala/highlights.scm @@ -263,7 +263,7 @@ "return" @keyword.control.return -(comment) @comment +[(comment) (block_comment)] @comment ;; `case` is a conditional keyword in case_block diff --git a/runtime/queries/scala/textobjects.scm b/runtime/queries/scala/textobjects.scm index fe0b8c25..6e551c41 100644 --- a/runtime/queries/scala/textobjects.scm +++ b/runtime/queries/scala/textobjects.scm @@ -51,8 +51,8 @@ ; Comment queries -(comment) @comment.inside -(comment) @comment.around ; Does not match consecutive block comments +[(comment) (block_comment)] @comment.inside +[(comment) (block_comment)] @comment.around ; Does not match consecutive block comments ; Test queries -- cgit v1.2.3-70-g09d2