Subject: Re: bug#73764: format-kbd-macro returns a key name that keymap-lookup doesn't recognize

From: Eli Zaretskii <[email-masked]>
Date: Mon, 14 Oct 2024 19:25:33 +0300

> Cc: [email-masked], [email-masked], [email-masked],
>  [email-masked]
> Date: Mon, 14 Oct 2024 18:54:27 +0300
> From: Eli Zaretskii <[email-masked]>
> 
> > From: Robert Pluim <[email-masked]>
> > Cc: Andreas Schwab <[email-masked]>,  [email-masked],
> >   [email-masked],  [email-masked]
> > Date: Mon, 14 Oct 2024 17:06:05 +0200
> > 
> > So if format-kbd-macro generates something with 'C-' in the "wrong"
> > place, whatʼs to stop us re-ordering the modifiers as a
> > post-processing step (inside `format-kbd-macro')?
> 
> If that's the only case where we put C- in the wrong place, then
> nothing stops us.  Is it?

In any case, there's the more general issue at hand here:
keymap--check is (at least in this case) unnecessarily restrictive:
where key-parse will gladly accept and correctly process a key whose
modifiers are in any order, keymap--check insist on the canonical
order.  I'm not sure I like this, at least in non-interactive
functions.