From c9ebd16c2884c3ab7463c6cafa0385971db7456b Mon Sep 17 00:00:00 2001 From: Stephan Seitz Date: Tue, 29 Jun 2021 21:34:52 +0200 Subject: [PATCH] python(folds): fold whole functions not only body --- queries/python/folds.scm | 19 ++++++++++--------- 1 file changed, 10 insertions(+), 9 deletions(-) diff --git a/queries/python/folds.scm b/queries/python/folds.scm index aacd0aaca..78e1e2c00 100644 --- a/queries/python/folds.scm +++ b/queries/python/folds.scm @@ -1,13 +1,14 @@ -(function_definition (block) @fold) -(class_definition (block) @fold) - -(while_statement (block) @fold) -(for_statement (block) @fold) -(if_statement (block) @fold) -(with_statement (block) @fold) -(try_statement (block) @fold) - [ + (function_definition) + (class_definition) + + (while_statement) + (for_statement) + (if_statement) + (with_statement) + (try_statement) + (match_statement) + (import_from_statement) (parameters) (argument_list)