From: Drew Adams <drew.adams@oracle.com>
To: Stefan Monnier <monnier@iro.umontreal.ca>
Cc: "casouri@gmail.com" <casouri@gmail.com>,
"60623@debbugs.gnu.org" <60623@debbugs.gnu.org>,
Theodor Thornhill <theo@thornhill.no>,
"eliz@gnu.org" <eliz@gnu.org>, Juri Linkov <juri@linkov.net>
Subject: bug#60623: 30.0.50; Add forward-sentence with tree sitter support
Date: Mon, 9 Jan 2023 15:57:16 +0000 [thread overview]
Message-ID: <SJ0PR10MB5488944C5C97E78C6C5C5100F3FE9@SJ0PR10MB5488.namprd10.prod.outlook.com> (raw)
In-Reply-To: <jwv4jt02pze.fsf-monnier+emacs@gnu.org>
> > Exactly. IMO, if the variable can have
^^
> > a nonfunction value, especially nil, then
>
> Bad idea.
I know you think so. ;-)
> That precludes changing the value of the
> variable with `add-function`,
Yes, it does, at least blindly and ignoring
its current value. And that's _appropriate_
IF the var can have a non-function value.
But even in that case the var value can be
tested to see if it's a function, and if/when
so, advising it can make sense.
> whereas `add-function` is often the best way for
> a major/minor mode to change that variable (actually, the "only" way to
> do it with some hope that it will interact correctly with other modes
> that may change it as well).
A legitimate argument. But it doesn't apply to
a variable already defined so that it "can have
a nonfunction value." Did you perhaps miss that
"if"?
I also don't agree that that (_good_) reason you
give is all-deciding.
I'd say that _other things being equal_, yes,
you can take advantage of that good reason, IF
the variable's value can be ensured to always be
a function, or sometimes even if it just is
currently a function.
IOW, you give one (good) reason for one (good)
practice, which, yes, can sometimes make sense.
> > there's no need (nothing gained, and even
> > possible confusion/misunderstanding added) by
> > adding "-default-" to the name.
> >
> > On the other hand, if the value must always
> > be a function, then having "-default-" in the
> > name makes sense.
>
> Agreed. It's also helpful when you look at the var's
> value, it lets you know that it hasn't been modified.
prev parent reply other threads:[~2023-01-09 15:57 UTC|newest]
Thread overview: 30+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-01-07 11:54 bug#60623: 30.0.50; Add forward-sentence with tree sitter support Theodor Thornhill via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-01-07 15:41 ` Daniel Martín via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-01-08 13:29 ` Theodor Thornhill via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-01-08 14:53 ` Eli Zaretskii
2023-01-08 19:35 ` Theodor Thornhill via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-01-08 19:57 ` Eli Zaretskii
2023-01-08 20:07 ` Theodor Thornhill via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-01-09 12:37 ` Eli Zaretskii
2023-01-09 13:28 ` Theodor Thornhill via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-01-10 8:37 ` Theodor Thornhill via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-01-10 15:07 ` Eli Zaretskii
2023-01-10 19:33 ` Theodor Thornhill via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-01-10 20:03 ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-01-10 20:22 ` Theodor Thornhill via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-01-10 20:28 ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-01-10 21:00 ` Drew Adams
2023-01-11 14:08 ` Eli Zaretskii
2023-01-11 14:41 ` Theodor Thornhill via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-01-08 17:33 ` Juri Linkov
2023-01-08 8:36 ` Juri Linkov
2023-01-08 9:20 ` Theodor Thornhill via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-01-08 16:41 ` Drew Adams
2023-01-08 17:04 ` Theodor Thornhill via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-01-08 17:30 ` Juri Linkov
2023-01-08 19:19 ` Theodor Thornhill via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-01-09 7:49 ` Juri Linkov
2023-01-09 8:01 ` Theodor Thornhill via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-01-08 17:42 ` Drew Adams
2023-01-09 6:20 ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-01-09 15:57 ` Drew Adams [this message]
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=SJ0PR10MB5488944C5C97E78C6C5C5100F3FE9@SJ0PR10MB5488.namprd10.prod.outlook.com \
--to=drew.adams@oracle.com \
--cc=60623@debbugs.gnu.org \
--cc=casouri@gmail.com \
--cc=eliz@gnu.org \
--cc=juri@linkov.net \
--cc=monnier@iro.umontreal.ca \
--cc=theo@thornhill.no \
/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.