unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: "Basil L. Contovounesios" via "Bug reports for GNU Emacs, the Swiss army knife of text editors" <bug-gnu-emacs@gnu.org>
To: Michael Heerdegen <michael_heerdegen@web.de>
Cc: Okam <okamsn@protonmail.com>, Lars Ingebrigtsen <larsi@gnus.org>,
	49407@debbugs.gnu.org, Nicolas Petton <nicolas@petton.fr>,
	Stefan Monnier <monnier@iro.umontreal.ca>
Subject: bug#49407: Request: Specify default values in `map-let` in Map.el
Date: Tue, 08 Aug 2023 14:41:28 +0200	[thread overview]
Message-ID: <87bkfhk8p3.fsf@epfl.ch> (raw)
In-Reply-To: <87cz08wwxk.fsf@web.de> (Michael Heerdegen's message of "Mon, 31 Jul 2023 06:02:15 +0200")

Michael Heerdegen [2023-07-31 06:02 +0200] wrote:

> Does this addition look appropriate?

Reads fine to me, so AFAIC feel free to install.
Just a couple of thoughts inline:

> diff --git a/lisp/emacs-lisp/map.el b/lisp/emacs-lisp/map.el
> index b55eb431668..04c00a2e908 100644
> --- a/lisp/emacs-lisp/map.el
> +++ b/lisp/emacs-lisp/map.el
> @@ -57,9 +57,10 @@ map
>  defaults to nil.  Both KEY and DEFAULT are evaluated.
>
>  Each element can also be a SYMBOL, which is an abbreviation of
> -a (KEY PAT) tuple of the form (\\='SYMBOL SYMBOL).  When SYMBOL
> -is a keyword, it is an abbreviation of the form (:SYMBOL SYMBOL),
> -useful for binding plist values.
> +a (KEY PAT) tuple of the form (\\='SYMBOL SYMBOL).  A keyword :FOO
> +is an abbreviation of the form (:FOO FOO), useful for binding plist values.

If you prefer to keep the stronger connectedness(?) between the
sentences, and/or avoid introducing a metaname with no inherent meaning:

                                                      Specifically
  when SYMBOL is a keyword :KEY, it is an abbreviation of the
  form (:KEY KEY), which can be useful for binding plist values.

> +See `map-elt' for an explanation of the used equality tests.

s/used/relevant/ would avoid the passive voice, if you prefer.
Or 'for details on key lookup', or ...

[ Trying to get on Eli's non-naughty list. ]

> If it's not clear: I changed :SYMBOL to :FOO because the original text
> called SYMBOL a keyword and then used SYMBOL and :SYMBOL (although then
> only :SYMBOL would be the keyword) - I found that confusing.  :KEYWORD
> would also be confusing, so I went with the placeholder "FOO".

I'm confused, I thought FOO stood For Obfuscation Only ;).

Thanks,
-- 
Basil





  reply	other threads:[~2023-08-08 12:41 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-07-04 23:08 bug#49407: Request: Specify default values in `map-let` in Map.el Okam via Bug reports for GNU Emacs, the Swiss army knife of text editors
2021-07-15  8:51 ` Lars Ingebrigtsen
2021-07-16  1:45   ` Okam via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-07-21  2:56   ` Okam via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-07-22  1:48     ` Michael Heerdegen
2023-07-22 15:45       ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-07-22 18:46       ` Okam via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-07-26  3:41         ` Michael Heerdegen
2023-07-27  1:39           ` Okam via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-07-28 18:02             ` Basil L. Contovounesios via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-07-28 19:19               ` Eli Zaretskii
2023-07-29  0:37               ` Okam via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-07-30 13:53                 ` Basil L. Contovounesios via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-07-31  4:02                   ` Michael Heerdegen
2023-08-08 12:41                     ` Basil L. Contovounesios via Bug reports for GNU Emacs, the Swiss army knife of text editors [this message]
2023-08-06 13:31                   ` Okam via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-08-08 12:46                     ` Basil L. Contovounesios via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-07-27  1:37 ` Earl Hyatt via Bug reports for GNU Emacs, the Swiss army knife of text editors

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

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87bkfhk8p3.fsf@epfl.ch \
    --to=bug-gnu-emacs@gnu.org \
    --cc=49407@debbugs.gnu.org \
    --cc=contovob@tcd.ie \
    --cc=larsi@gnus.org \
    --cc=michael_heerdegen@web.de \
    --cc=monnier@iro.umontreal.ca \
    --cc=nicolas@petton.fr \
    --cc=okamsn@protonmail.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 public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).