unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
* Meta characters in strings
@ 2008-11-29 12:03 Eli Zaretskii
  2008-11-29 19:57 ` Stefan Monnier
  0 siblings, 1 reply; 4+ messages in thread
From: Eli Zaretskii @ 2008-11-29 12:03 UTC (permalink / raw)
  To: emacs-devel; +Cc: handa

Is this text from the ELisp manual still correct?

      Sometimes key sequences are represented as strings.  When a string is
    a key sequence, string elements in the range 128 to 255 represent meta
    characters (which are large integers) rather than character
    codes in the range 128 to 255.




^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Meta characters in strings
  2008-11-29 12:03 Meta characters in strings Eli Zaretskii
@ 2008-11-29 19:57 ` Stefan Monnier
  2008-11-29 21:35   ` Eli Zaretskii
  0 siblings, 1 reply; 4+ messages in thread
From: Stefan Monnier @ 2008-11-29 19:57 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: handa, emacs-devel

> Is this text from the ELisp manual still correct?
>       Sometimes key sequences are represented as strings.  When a string is
>     a key sequence, string elements in the range 128 to 255 represent meta
>     characters (which are large integers) rather than character
>     codes in the range 128 to 255.

Almost: it's only true if the string is unibyte.


        Stefan




^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Meta characters in strings
  2008-11-29 19:57 ` Stefan Monnier
@ 2008-11-29 21:35   ` Eli Zaretskii
  2008-11-30  5:35     ` Stefan Monnier
  0 siblings, 1 reply; 4+ messages in thread
From: Eli Zaretskii @ 2008-11-29 21:35 UTC (permalink / raw)
  To: Stefan Monnier; +Cc: handa, emacs-devel

> From: Stefan Monnier <monnier@iro.umontreal.ca>
> Cc: emacs-devel@gnu.org,  handa@m17n.org
> Date: Sat, 29 Nov 2008 14:57:40 -0500
> 
> > Is this text from the ELisp manual still correct?
> >       Sometimes key sequences are represented as strings.  When a string is
> >     a key sequence, string elements in the range 128 to 255 represent meta
> >     characters (which are large integers) rather than character
> >     codes in the range 128 to 255.
> 
> Almost: it's only true if the string is unibyte.

That's not what I see:

  (multibyte-char-to-unibyte ?\M-a)
     => wrong-type-argument characterp 134217825

What am I missing?




^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Meta characters in strings
  2008-11-29 21:35   ` Eli Zaretskii
@ 2008-11-30  5:35     ` Stefan Monnier
  0 siblings, 0 replies; 4+ messages in thread
From: Stefan Monnier @ 2008-11-30  5:35 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: handa, emacs-devel

>> > Is this text from the ELisp manual still correct?
>> >       Sometimes key sequences are represented as strings.  When a string is
>> >     a key sequence, string elements in the range 128 to 255 represent meta
>> >     characters (which are large integers) rather than character
>> >     codes in the range 128 to 255.
>> 
>> Almost: it's only true if the string is unibyte.

> That's not what I see:

>   (multibyte-char-to-unibyte ?\M-a)
>      => wrong-type-argument characterp 134217825

Why do you think this is related to the text you quoted?

> What am I missing?

The text only talks about what happens if you do

   (define-key map "\M-a" 'foo)

Note that "\M-a" is a unibyte string whose first byte is 225.


        Stefan




^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2008-11-30  5:35 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-11-29 12:03 Meta characters in strings Eli Zaretskii
2008-11-29 19:57 ` Stefan Monnier
2008-11-29 21:35   ` Eli Zaretskii
2008-11-30  5:35     ` Stefan Monnier

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).