all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Eli Zaretskii <eliz@gnu.org>
To: "João Távora" <joaotavora@gmail.com>
Cc: monnier@iro.umontreal.ca, emacs-devel@gnu.org
Subject: Re: jit-lock-antiblink-grace
Date: Sat, 12 Oct 2019 19:04:59 +0300	[thread overview]
Message-ID: <83o8ymlzkk.fsf@gnu.org> (raw)
In-Reply-To: <CALDnm50oemzs5M9hDEcWrFtS54=kFeWLh++P96FAk_05_i-Xeg@mail.gmail.com> (message from João Távora on Sat, 12 Oct 2019 15:23:08 +0100)

> From: João Távora <joaotavora@gmail.com>
> Date: Sat, 12 Oct 2019 15:23:08 +0100
> Cc: emacs-devel <emacs-devel@gnu.org>, Stefan Monnier <monnier@iro.umontreal.ca>
> 
> > The post-command-hook is notorious for slowing down cursor motion.
> 
> Probably a fame unjustly inherited from functions that people put there.

Not people: our own minor modes.

> > I'm not sure I understand.  What I wanted to suggest is that when the
> > new defcustom is nil (which seems to be the way to disable this
> > feature), the post-command-hook should not be added.
> 
> If we do it like that, it will take effect only when jit-lock-mode is
> toggled.  Therefore, if you set the variable to nil in a buffer you will
> only see the desired effects in post-command-hook after additionally
> toggling jit-lock-mode on and off again.

It doesn't have to be like that.  It depends on how you arrange for
the hook not to be added.

> > I'd rather had you try.  I think it's important that more people can
> > write good documentation, and I think in this case it isn't hard.  You
> > can use other entries as examples.
> 
> Naturally Eli, I hope you believe me that I try hard, indeed very hard,
> to write good documentation.  I spend I good deal of time in it,
> sometimes much more than writing the code itself.  If I sometimes fail
> to meet your standards, it's to be expected, (1) because they are high
> (which is very good) and (2) because we all have unwritten guidelines of
> what we believe is good style.  I tried many versions (many more than
> you can probably get evidence of in the emacs-diffs ML) and settled on
> the one I presented.
> 
> With requesting a suggestion from you, I am not taking an adversarial
> position, simply a way forward on what I (and many) consider to be a
> difficult and underestimated problem in programming.  Also, English is
> not my first language, and Emacs-english has certain rules that you will
> much more familiar with.

All I wanted to say was that the goal is almost in reach, and that you
don't need to give up in this case.

But if you think it's too hard, then okay, I will write the text when
the time comes.

> > It's a backward-incompatible behavior, and is not being developed due
> > to bug reports, so why make it the default right from the start?  It
> > also slows down cursor motion (which should probably be in the doc
> > string as well).
> 
> Regarding slowdown, we have to check by how much.  Regarding the
> pertinence of the modificaiton, there are mode-specific modifications
> with (IMO much worse) backward-incompatible behaviour being made to
> modes like to c-mode to circumvent precisely this problem.  Perhaps you
> could weigh in on the pertinence of those on-by-default (and moreover
> impossible-to-turn-off) alternatives, too.  Although those other
> modifications target a reduced subset of modes, indeed precisely because
> of that fact, I think it's better that Emacs provides an effective and
> more generic solution to this problem.

When I find a backward-incompatible change, I usually do try to see if
it's justified.  So I think I already do what you ask me to do in
those other cases.

> > I still don't think I understand what would constitute an
> > "unterminated string at EOL", then.  Could you show two examples, one
> > where there is such a string, the other where there isn't?
> 
> Buffer 1:
> 
> l1: foofoo "bar            < unterminated string at EOL, terminated multiline string
> l2: barbar" foofoo
> 
> Buffer 2:
> 
> l1: foofoo "bar            < unterminated string at EOL, unterminated string
> l2: barbar
> 
> It's an informal way of referring to both situations at line 1.

That's what I thought, but then I think we should rather talk about
"unbalanced quotes", which should catch both cases without involving
EOL.

> > Why not just lose the message? 
> 
> Huh? If I lose the message the form becomes a noop.

I meant lose the entire form.  Why should a user care that there was
already a timer?  Will that adversely affect the code in some way?

> Run-time consistency assertions are useful, right?

Only as a debug option, or if the code absolutely cannot continue
under that condition.  Which I think is not the case here.



  reply	other threads:[~2019-10-12 16:04 UTC|newest]

Thread overview: 58+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-10-10 22:34 jit-lock-antiblink-grace João Távora
2019-10-11 14:26 ` jit-lock-antiblink-grace Stefan Monnier
2019-10-12  9:34 ` jit-lock-antiblink-grace Eli Zaretskii
2019-10-12 10:57   ` jit-lock-antiblink-grace João Távora
2019-10-12 13:02     ` jit-lock-antiblink-grace Juanma Barranquero
2019-10-12 13:14       ` jit-lock-antiblink-grace João Távora
2019-10-12 14:50         ` jit-lock-antiblink-grace Juanma Barranquero
2019-10-12 15:11           ` jit-lock-antiblink-grace João Távora
2019-10-12 15:30             ` jit-lock-antiblink-grace Juanma Barranquero
2019-10-12 13:32     ` jit-lock-antiblink-grace Eli Zaretskii
2019-10-12 14:13       ` jit-lock-antiblink-grace Stefan Monnier
2019-10-12 14:23         ` jit-lock-antiblink-grace Eli Zaretskii
2019-10-12 14:34           ` jit-lock-antiblink-grace Stefan Monnier
2019-10-12 15:57             ` jit-lock-antiblink-grace Eli Zaretskii
2019-10-12 17:16               ` jit-lock-antiblink-grace Stefan Monnier
2019-10-12 17:50                 ` jit-lock-antiblink-grace Eli Zaretskii
2019-10-12 15:47         ` jit-lock-antiblink-grace Alan Mackenzie
2019-10-12 14:23       ` jit-lock-antiblink-grace João Távora
2019-10-12 16:04         ` Eli Zaretskii [this message]
2019-10-12 21:55           ` jit-lock-antiblink-grace João Távora
2019-10-13  6:39             ` jit-lock-antiblink-grace Eli Zaretskii
2019-10-13  8:47               ` jit-lock-antiblink-grace João Távora
2019-10-13  9:22                 ` jit-lock-antiblink-grace Eli Zaretskii
2019-10-13 10:28                   ` jit-lock-antiblink-grace João Távora
2019-10-13 10:45                     ` jit-lock-antiblink-grace Eli Zaretskii
2019-10-14 23:29                       ` jit-lock-antiblink-grace João Távora
2019-10-15  6:48                         ` jit-lock-antiblink-grace Eli Zaretskii
2019-10-15 18:28                           ` jit-lock-antiblink-grace João Távora
2019-11-24  1:04                             ` jit-lock-antiblink-grace João Távora
2019-11-24 16:16                               ` jit-lock-antiblink-grace Eli Zaretskii
2019-11-25 18:46                                 ` jit-lock-antiblink-grace Alan Mackenzie
2019-11-25 19:02                                   ` jit-lock-antiblink-grace João Távora
2019-11-25 19:26                                     ` jit-lock-antiblink-grace Alan Mackenzie
2019-11-25 19:45                                       ` jit-lock-antiblink-grace João Távora
2019-11-25 20:11                                         ` jit-lock-antiblink-grace Alan Mackenzie
2019-11-25 20:23                                           ` jit-lock-antiblink-grace João Távora
2019-11-25 21:07                                             ` jit-lock-antiblink-grace João Távora
2019-11-26  2:30                                               ` jit-lock-antiblink-grace João Távora
2019-11-26 17:58                                                 ` jit-lock-antiblink-grace Eli Zaretskii
2019-11-30 19:11                                                   ` jit-lock-antiblink-grace João Távora
2019-11-30 19:22                                                     ` jit-lock-antiblink-grace Eli Zaretskii
2019-11-30 20:12                                                       ` jit-lock-antiblink-grace João Távora
2019-11-30 20:16                                                         ` jit-lock-antiblink-grace Eli Zaretskii
2019-11-30 20:19                                                           ` jit-lock-antiblink-grace João Távora
2019-11-30 20:41                                                             ` jit-lock-antiblink-grace Eli Zaretskii
2019-11-30 22:00                                                               ` jit-lock-antiblink-grace João Távora
2019-12-01 18:13                                                                 ` jit-lock-antiblink-grace Eli Zaretskii
2019-12-04 22:45                                                                   ` jit-lock-antiblink-grace João Távora
2019-12-05 15:40                                                                     ` jit-lock-antiblink-grace Eli Zaretskii
2019-11-26 13:43                                           ` jit-lock-antiblink-grace Stefan Monnier
2019-11-25 19:47                                       ` jit-lock-antiblink-grace Dmitry Gutov
2019-11-25 20:03                                         ` jit-lock-antiblink-grace João Távora
2019-10-12 16:14         ` jit-lock-antiblink-grace Alan Mackenzie
2019-10-12 22:26           ` jit-lock-antiblink-grace João Távora
2019-10-13 10:18             ` jit-lock-antiblink-grace Alan Mackenzie
2019-10-13 10:48               ` jit-lock-antiblink-grace João Távora
2019-10-13 12:02 ` jit-lock-antiblink-grace Alan Mackenzie
2019-10-13 19:57   ` jit-lock-antiblink-grace João Távora

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=83o8ymlzkk.fsf@gnu.org \
    --to=eliz@gnu.org \
    --cc=emacs-devel@gnu.org \
    --cc=joaotavora@gmail.com \
    --cc=monnier@iro.umontreal.ca \
    /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.