[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [SPAM UNSURE] Re: Plug treesit.el into other emacs constructs
From: |
Kévin Le Gouguec |
Subject: |
Re: [SPAM UNSURE] Re: Plug treesit.el into other emacs constructs |
Date: |
Sat, 17 Dec 2022 16:30:31 +0100 |
User-agent: |
Gnus/5.13 (Gnus v5.13) |
Stephen Leake <stephen_leake@stephe-leake.org> writes:
> Kévin Le Gouguec <kevin.legouguec@gmail.com> writes:
>
>> Stephen Leake <stephen_leake@stephe-leake.org> writes:
>>
>>> ada-mode has something similar; forward-sexp goes to the next labeled
>>> keyword. That's more useful than stopping at every little AST node. It
>>> relies on markup in the grammar to label the keywords; tree-sitter would
>>> need another markup similar to the current indent markup.
>>
>> Chiming in since I got bitten by this in ada-mode right now: as someone
>> used to mark long_identifiers_with_underscores with C-M-SPC in other
>> modes, it's tripping me up that mark-sexp (and sexp movement in general)
>> "overshoots" and goes over much bigger expressions in ada-mode.
>
> Sounds like we need an option for this in ada-mode?
That'd be very welcome indeed, as far as I am concerned (no rush though;
I can take a stab at it on a rainy day if no-one else is clamoring for
it).
> My solution to this is to bind C-<right> to (forward-symbol 1), and
> C-<left> to (forward-symbol -1), so these keys move over whole
> identifiers.
Interesting; I don't think the *-symbol commands were on my radar (no
mark-symbol though AFAICT).
(I see now we also have {forward,backward}-list, bound to C-M-{n,p};
that's another pair I don't often use; I do use C-M-{d,u} a lot, but for
"horizontal" traversal I usually rely on C-M-{f,b})
- Re: Plug treesit.el into other emacs constructs, (continued)
- Re: Plug treesit.el into other emacs constructs, Theodor Thornhill, 2022/12/15
- Re: Plug treesit.el into other emacs constructs, Stefan Monnier, 2022/12/14
- Re: Plug treesit.el into other emacs constructs, Theodor Thornhill, 2022/12/15
- Re: Plug treesit.el into other emacs constructs, Yuan Fu, 2022/12/15
- Re: Plug treesit.el into other emacs constructs, Theodor Thornhill, 2022/12/15
- Re: Plug treesit.el into other emacs constructs, Theodor Thornhill, 2022/12/13
- Re: Plug treesit.el into other emacs constructs, Stefan Monnier, 2022/12/13
Re: Plug treesit.el into other emacs constructs, Stephen Leake, 2022/12/14