From 5ec42175676bc4e6248b8ca9603acbc86497c68e Mon Sep 17 00:00:00 2001 From: Christoph Sax Date: Wed, 13 Sep 2023 20:54:04 +0200 Subject: fix(t32): update indent queries & test The latest release of the grammar changes the handling of consecutive line breaks. This breaks the existing test for indents. This commit updates the indent queries and fixes the associated test. --- queries/t32/indents.scm | 22 ++++------------------ 1 file changed, 4 insertions(+), 18 deletions(-) (limited to 'queries') diff --git a/queries/t32/indents.scm b/queries/t32/indents.scm index 64ee3f571..b30b916d2 100644 --- a/queries/t32/indents.scm +++ b/queries/t32/indents.scm @@ -1,28 +1,15 @@ -; Subroutines & scoping (block ")" @indent.branch .) @indent.begin +(if_block) @indent.begin -; Control flow statements -( - (if_block - condition: (_) - . (_) @_then) @indent.begin - (#not-has-type? @_then block) -) +(if_block + (block)) @indent.dedent (else_block) @indent.branch (else_block - (if_block) @indent.dedent) @indent.branch - -( - (else_block - (if_block - condition: (_) - . (_) @_then)) @indent.branch - (#not-has-type? @_then block) -) + (if_block) @indent.dedent) (while_block (command_expression)) @indent.auto @@ -30,5 +17,4 @@ (repeat_block (command_expression)) @indent.auto - (comment) @indent.auto -- cgit v1.2.3-70-g09d2