[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Fixing post-self-insert-hook.
From: |
Eli Zaretskii |
Subject: |
Re: Fixing post-self-insert-hook. |
Date: |
Sat, 18 Sep 2021 08:50:26 +0300 |
> Date: Fri, 17 Sep 2021 19:37:27 +0000
> From: Alan Mackenzie <acm@muc.de>
> Cc: João Távora <joaotavora@gmail.com>
>
> Given that it is now (at least politically) impossible to ban buffer
> changing post-self-insert-hook functions, I propose to change the time at
> which the hook gets called.
>
> Instead of getting called straight after the self-insert-command, it
> should be called at the end of the command which called
> self-insert-command. Just before post-command-hook, perhaps. Yes there
> are details to be worked out.
>
> This will make no difference to the usual self-insert-command call. It
> will, however, restore the certainty of processing to Lisp code such as
> c-electric-brace without having to resort to ugly workarounds.
If CC Mode has problem with these hooks, it could bind them to nil
around the call to self-insert-command, couldn't it? That'd be much
better than making any globally-visible change in behavior, for which
we cannot possibly know the unintended consequences.
In any case, please let's not make this change before the emacs-28
branch is cut, as it can potentially disrupt many places.
- Re: Fixing post-self-insert-hook., (continued)
Re: Fixing post-self-insert-hook., João Távora, 2021/09/17
Re: Fixing post-self-insert-hook.,
Eli Zaretskii <=