From: Stefan Monnier via "Bug reports for GNU Emacs, the Swiss army knife of text editors" <bug-gnu-emacs@gnu.org>
To: Don March <don@ohspite.net>
Cc: 7631@debbugs.gnu.org, Lars Ingebrigtsen <larsi@gnus.org>
Subject: bug#7631: 24.0.50; inconsistency in event-convert-list and event-basic-type
Date: Sun, 18 Jul 2021 12:09:43 -0400 [thread overview]
Message-ID: <jwv35sbd30y.fsf-monnier+emacs@gnu.org> (raw)
In-Reply-To: <AANLkTikZoQWmHuPb7ZZ3kWQjMrPJbPN0BLgmVEna2Acp@mail.gmail.com> (Don March's message of "Mon, 13 Dec 2010 22:36:20 -0500")
Don March wrote:
> (event-convert-list
> (append (event-modifiers event)
> (list (event-basic-type event)))) ; => 116, not t
>
> In my mind, this should be an identity function (in the mathematical
> sense) for events;
In general, it literally can't be: there are several "equivalent"
representations of a given event and `event-convert-list` should return
a "canonical" version. E.g. it should return `C-M-return` when `event`
is `M-C-return`.
There is no "canonical event" `t`, instead Emacs uses `?t` as the
canonical event for hitting the key `t`.
Lars wrote:
> So if this isn't a bug (and I think it would be problematic to change
> the return value at this point), the doc string is at least slightly
> misleading here, and shouldn't claim that it returns exactly the same
> base event type.
Fair enough,
Stefan
next prev parent reply other threads:[~2021-07-18 16:09 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-12-13 6:22 bug#7631: 24.0.50; inconsistency in event-convert-list and event-basic-type Don March
2010-12-13 18:01 ` Stefan Monnier
2010-12-14 3:36 ` Don March
2021-07-18 12:20 ` Lars Ingebrigtsen
2021-07-18 16:09 ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors [this message]
2021-07-18 16:18 ` Lars Ingebrigtsen
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=jwv35sbd30y.fsf-monnier+emacs@gnu.org \
--to=bug-gnu-emacs@gnu.org \
--cc=7631@debbugs.gnu.org \
--cc=don@ohspite.net \
--cc=larsi@gnus.org \
--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 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).