From: Dmitry Gutov <dgutov@yandex.ru>
To: Alan Mackenzie <acm@muc.de>
Cc: yyoncho@gmail.com, 38406@debbugs.gnu.org
Subject: bug#38406: 27.0.50; post-self-insert-hook does not hold its contract in cc-mode derived modes
Date: Thu, 5 Dec 2019 22:44:55 +0200 [thread overview]
Message-ID: <1c3dea25-5606-76d5-b35d-2486583b8f38@yandex.ru> (raw)
In-Reply-To: <20191205191459.GB6252@ACM>
On 05.12.2019 21:14, Alan Mackenzie wrote:
> On Wed, Dec 04, 2019 at 23:04:27 +0200, Dmitry Gutov wrote:
>> On 04.12.2019 22:41, Alan Mackenzie wrote:
>>> +(defvar c--unsafe-post-self-insert-hook-functions
>>> + '(smie-blink-matching-open
>>> + electric-pair-post-self-insert-function
>>> + blink-paren-post-self-insert-function
>>> + electric-indent-post-self-insert-function
>>> + electric-layout-post-self-insert-function
>>> + electric-quote-post-self-insert-function)
>>> + "Known unsafe functions when members of `post-self-insert-hook' in CC Mode")
>
>> I don't see how filtering out a bunch of popular consumers of
>> post-self-insert-hook can make it "act as per its contract again".
>
> Think of it more as "filtering in" all functions on
> post-self-insert-hook _except_ the ones mentioned, which are harmful in
> CC Mode.
blink-paren is harmful for CC Mode? Or is it reimplemented, like other
features (e.g. electric-*), inside CC Mode?
In the latter case, I think CC Mode should just disable the respective
minor modes/variables locally and call it a day (the hook won't be used
them, so no need for filtering).
Of course, ideally users of recent enough Emacs would be able to disable
these built-in features and switch on the generic ones instead.
next prev parent reply other threads:[~2019-12-05 20:44 UTC|newest]
Thread overview: 29+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-11-27 20:00 bug#38406: 27.0.50; post-self-insert-hook does not hold its contract in cc-mode derived modes yyoncho
2019-11-30 14:36 ` Alan Mackenzie
2019-12-01 10:02 ` yyoncho
2019-12-01 15:07 ` Alan Mackenzie
2019-12-01 15:27 ` yyoncho
2019-12-01 15:58 ` Alan Mackenzie
2019-12-01 18:03 ` Eli Zaretskii
2019-12-02 18:37 ` Alan Mackenzie
2019-12-01 17:59 ` Eli Zaretskii
2019-12-01 19:27 ` Alan Mackenzie
2019-12-01 20:47 ` Eli Zaretskii
2019-12-02 18:31 ` Alan Mackenzie
2019-12-02 20:17 ` Eli Zaretskii
2019-12-04 20:41 ` Alan Mackenzie
2019-12-04 21:04 ` Dmitry Gutov
2019-12-05 19:14 ` Alan Mackenzie
2019-12-05 20:44 ` Dmitry Gutov [this message]
2019-12-05 14:45 ` Eli Zaretskii
2019-12-05 19:09 ` Alan Mackenzie
2019-12-05 19:25 ` Eli Zaretskii
2019-12-05 20:17 ` Alan Mackenzie
2019-12-06 8:06 ` Eli Zaretskii
2019-12-06 18:28 ` Alan Mackenzie
2019-12-06 18:48 ` Eli Zaretskii
2019-12-06 22:24 ` Alan Mackenzie
2019-12-07 8:21 ` Eli Zaretskii
2019-12-07 11:40 ` Alan Mackenzie
2019-12-07 13:27 ` Eli Zaretskii
2019-12-07 19:03 ` Alan Mackenzie
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1c3dea25-5606-76d5-b35d-2486583b8f38@yandex.ru \
--to=dgutov@yandex.ru \
--cc=38406@debbugs.gnu.org \
--cc=acm@muc.de \
--cc=yyoncho@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.