From ec1e4f4c01bd221036ee6f015acf022a119ebc07 Mon Sep 17 00:00:00 2001 From: Daniel Poulin Date: Tue, 5 Sep 2023 08:06:40 -0400 Subject: [PATCH] Add element textobject queries for python --- runtime/queries/python/textobjects.scm | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/runtime/queries/python/textobjects.scm b/runtime/queries/python/textobjects.scm index 966e47446a692..b50b68916b1dc 100644 --- a/runtime/queries/python/textobjects.scm +++ b/runtime/queries/python/textobjects.scm @@ -21,3 +21,20 @@ name: (identifier) @_name body: (block)? @test.inside) @test.around (#match? @_name "^test_")) + +(list + (_) @element.around) + +(tuple + (_) @element.around) + +(set + (_) @element.around) + +(pair + (_) @element.inside) @element.around + +(class_definition + (block + (expression_statement + (assignment) @element.around)))