emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Plug treesit.el into other emacs constructs


From: Theodor Thornhill
Subject: Re: Plug treesit.el into other emacs constructs
Date: Tue, 27 Dec 2022 23:15:26 +0100

Stefan Monnier <monnier@iro.umontreal.ca> writes:

>>> +  (let* ((aux (if special mover
>>> +           (lambda (x)
>>> +             (cons (progn (funcall mover x) (point))
>>> +                   (progn (funcall mover (- x)) (point))))))
>>
>> If `mover` is changed to return a pair of positions, than the above can
>> just be:
>
> [ ... and here I hit `C-c C-c` i.s.o `C-x C-x`, sorry.  ]
>
>     (let* ((aux (if special mover
>                   (lambda (x)
>                           (let ((pos (progn (funcall mover x) (point))))
>                             (if (consp pos) pos
>                         (cons pos
>                             (progn (funcall mover (- x)) (point))))))))
>

I think I managed to keep the semantics as they are now.  What do you
think?  Does this seem like a sane approach?

Theo

Attachment: 0001-Add-treesit-transpose-sexps-bug-60128.patch
Description: Text Data


reply via email to

[Prev in Thread] Current Thread [Next in Thread]