[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#59662: 29.0.50; [PATCH] Add treesit--indent-defun
From: |
Eli Zaretskii |
Subject: |
bug#59662: 29.0.50; [PATCH] Add treesit--indent-defun |
Date: |
Thu, 08 Dec 2022 09:16:00 +0200 |
> Date: Thu, 8 Dec 2022 03:37:54 +0200
> Cc: theo@thornhill.no, casouri@gmail.com, 59662@debbugs.gnu.org,
> casouri@gmail.org
> From: Dmitry Gutov <dgutov@yandex.ru>
>
> >> AFAICT, these behaviors are quite compatible. But paredit's binding
> >> seems to be useful in more contexts.
> > I'm fine with trying something like that on master, to see whether users
> > like this conflation, but not on the release branch.
>
> Here's a patch that people can try. From my brief testing, seems useful
> enough. I suppose some might dislike it, though, in some codebases where
> the methods/functions are consistently longer than a screenful. I do
> like this binding in Emacs Lisp too, though.
Stefan, Lars: any comments?
I'm okay with installing this on master, but please rename the new
function to something like prog-fill-reindent; the "fill" part should
appear in the name, to explain why we have both prog-indent and this
function.
Also, a NEWS entry and some addition to the "Multi-line Indent" node
of the Emacs user manual would be nice.
Bonus points for adding something that could use treesit.el
capabilities, when those are available, instead of syntax-ppss, to
determine when we are in a comment or in a string. Or maybe Theo or
Yuan could suggest such an addition.
Thanks.
- bug#59662: 29.0.50; [PATCH] Add treesit--indent-defun, (continued)
bug#59662: 29.0.50; [PATCH] Add treesit--indent-defun, Dmitry Gutov, 2022/12/02
- bug#59662: 29.0.50; [PATCH] Add treesit--indent-defun, Dmitry Gutov, 2022/12/02
- bug#59662: 29.0.50; [PATCH] Add treesit--indent-defun, Theodor Thornhill, 2022/12/02
- bug#59662: 29.0.50; [PATCH] Add treesit--indent-defun, Dmitry Gutov, 2022/12/02
- bug#59662: 29.0.50; [PATCH] Add treesit--indent-defun, Eli Zaretskii, 2022/12/03
- bug#59662: 29.0.50; [PATCH] Add treesit--indent-defun, Dmitry Gutov, 2022/12/03
- bug#59662: 29.0.50; [PATCH] Add treesit--indent-defun, Eli Zaretskii, 2022/12/03
- bug#59662: 29.0.50; [PATCH] Add treesit--indent-defun, Dmitry Gutov, 2022/12/07
- bug#59662: 29.0.50; [PATCH] Add treesit--indent-defun,
Eli Zaretskii <=
- bug#59662: 29.0.50; [PATCH] Add treesit--indent-defun, Theodor Thornhill, 2022/12/08
- bug#59662: 29.0.50; [PATCH] Add treesit--indent-defun, Eli Zaretskii, 2022/12/08
- bug#59662: 29.0.50; [PATCH] Add treesit--indent-defun, Theodor Thornhill, 2022/12/08
- bug#59662: 29.0.50; [PATCH] Add treesit--indent-defun, Theodor Thornhill, 2022/12/08
- bug#59662: 29.0.50; [PATCH] Add treesit--indent-defun, Eli Zaretskii, 2022/12/08
- bug#59662: 29.0.50; [PATCH] Add treesit--indent-defun, Theodor Thornhill, 2022/12/08
- bug#59662: 29.0.50; [PATCH] Add treesit--indent-defun, Eli Zaretskii, 2022/12/08
- bug#59662: 29.0.50; [PATCH] Add treesit--indent-defun, Dmitry Gutov, 2022/12/08
- bug#59662: 29.0.50; [PATCH] Add treesit--indent-defun, Theodor Thornhill, 2022/12/08
- bug#59662: 29.0.50; [PATCH] Add treesit--indent-defun, Dmitry Gutov, 2022/12/08